Skip to content

Commit

Permalink
fixed lint
Browse files Browse the repository at this point in the history
  • Loading branch information
silaslenihan committed Feb 20, 2025
1 parent 6b6ec83 commit ef7de91
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
6 changes: 4 additions & 2 deletions contracts/programs/contract-reader-interface/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -109,15 +109,17 @@ pub mod contract_reader_interface {

pub fn store_token_account(ctx: Context<StoreTokenAccount>, test_idx: u64) -> Result<()> {
let account = ctx.accounts.token_account.to_account_info();
require!(!account.data_is_empty(), TokenAccountError::UninitializedTokenAccount);
require!(
!account.data_is_empty(),
TokenAccountError::UninitializedTokenAccount
);

let data = &mut ctx.accounts.data;
data.idx = test_idx;
data.account = account.key();
data.bump = ctx.bumps.data;
Ok(())
}

}

#[derive(Accounts)]
Expand Down
4 changes: 2 additions & 2 deletions pkg/solana/chainwriter/chain_writer.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,8 +296,8 @@ func (s *SolanaChainWriterService) SubmitTransaction(ctx context.Context, contra

if len(methodConfig.ATAs) > 0 {
s.lggr.Debugw("Creating ATAs", "contract", contractName, "method", method)
createATAInstructions, err := CreateATAs(ctx, args, methodConfig.ATAs, derivedTableMap, s.client, feePayer, s.lggr)
if err != nil {
createATAInstructions, ataErr := CreateATAs(ctx, args, methodConfig.ATAs, derivedTableMap, s.client, feePayer, s.lggr)
if ataErr != nil {
return errorWithDebugID(fmt.Errorf("error resolving account addresses: %w", err), debugID)
}
if err = s.handleATACreation(ctx, createATAInstructions, methodConfig, contractName, method, feePayer); err != nil {
Expand Down

0 comments on commit ef7de91

Please sign in to comment.