Skip to content

Commit

Permalink
Merge pull request #249 from InjectiveLabs/fix/check_tx_result_in_syn…
Browse files Browse the repository at this point in the history
…c_broadcast_before_await

fix/check_tx_result_in_sync_broadcast_before_await
  • Loading branch information
PavelInjective authored Oct 3, 2024
2 parents 92ece76 + be869a6 commit 94c4b2c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions client/chain/chain.go
Original file line number Diff line number Diff line change
Expand Up @@ -833,7 +833,7 @@ func (c *chainClient) SyncBroadcastSignedTx(txBytes []byte) (*txtypes.BroadcastT
ctx := context.Background()

res, err := common.ExecuteCall(ctx, c.network.ChainCookieAssistant, c.txClient.BroadcastTx, &req)
if err != nil {
if err != nil || res.TxResponse.Code != 0 {
return res, err
}

Expand Down Expand Up @@ -904,7 +904,7 @@ func (c *chainClient) broadcastTx(
}

res, err := common.ExecuteCall(context.Background(), c.network.ChainCookieAssistant, c.txClient.BroadcastTx, &req)
if !await || err != nil {
if err != nil || res.TxResponse.Code != 0 || !await {
return res, err
}

Expand Down

0 comments on commit 94c4b2c

Please sign in to comment.