From 1c8c70c668ed7bd7416a0c10bbf374edc63b8c7e Mon Sep 17 00:00:00 2001 From: brewmaster012 <88689859+brewmaster012@users.noreply.github.com> Date: Wed, 2 Oct 2024 14:16:34 -0500 Subject: [PATCH] address some CI complaints --- programs/protocol-contracts-solana/src/lib.rs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/programs/protocol-contracts-solana/src/lib.rs b/programs/protocol-contracts-solana/src/lib.rs index ede9234..e42eb27 100644 --- a/programs/protocol-contracts-solana/src/lib.rs +++ b/programs/protocol-contracts-solana/src/lib.rs @@ -84,7 +84,11 @@ pub mod gateway { Ok(()) } - pub fn deposit(ctx: Context, amount: u64, receiver: [u8; 20]) -> Result<()> { + pub fn deposit( + ctx: Context, + amount: u64, + receiver: [u8; 20], // not used in this program; for directing zetachain protocol only + ) -> Result<()> { let pda = &mut ctx.accounts.pda; require!(!pda.deposit_paused, Errors::DepositPaused); @@ -114,13 +118,13 @@ pub mod gateway { ) -> Result<()> { require!(message.len() <= 512, Errors::MemoLengthExceeded); deposit(ctx, amount, receiver)?; - return Ok(()); + Ok(()) } pub fn deposit_spl_token( ctx: Context, amount: u64, - receiver: [u8; 20], + receiver: [u8; 20], // unused in this program; for directing zetachain protocol only ) -> Result<()> { let token = &ctx.accounts.token_program; let from = &ctx.accounts.from; @@ -161,7 +165,7 @@ pub mod gateway { ) -> Result<()> { require!(message.len() <= 512, Errors::MemoLengthExceeded); deposit_spl_token(ctx, amount, receiver)?; - return Ok(()); + Ok(()); } // require tss address signature on the internal message defined in the following