Skip to content

Commit

Permalink
refactor: return err directly
Browse files Browse the repository at this point in the history
  • Loading branch information
cuiweixie committed Jul 8, 2024
1 parent 6ab7f61 commit 4fdd17a
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions relayer/chains/cosmos/tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -1676,10 +1676,7 @@ func (cc *CosmosProvider) PrepareFactory(txf tx.Factory, signingKey string) (tx.

// Set the account number and sequence on the transaction factory and retry if fail
if err = retry.Do(func() error {
if err = txf.AccountRetriever().EnsureExists(cliCtx, from); err != nil {
return err
}
return err
return txf.AccountRetriever().EnsureExists(cliCtx, from)
}, rtyAtt, rtyDel, rtyErr); err != nil {
return txf, err
}
Expand Down

0 comments on commit 4fdd17a

Please sign in to comment.