Skip to content

Commit

Permalink
utils: fix DecodeRevertReason
Browse files Browse the repository at this point in the history
  • Loading branch information
attente committed Mar 3, 2025
1 parent c62a4a5 commit da76a14
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ import (
v3 "github.com/0xsequence/go-sequence/core/v3"
)

// var zeroAddress = common.Address{}

func DeploySequenceWallet(sender *ethwallet.Wallet, walletConfig core.WalletConfig, walletContext WalletContext) (common.Address, *types.Transaction, ethtxn.WaitReceipt, error) {
if sender.GetProvider() == nil {
return common.Address{}, nil, nil, ErrProviderNotSet
Expand Down Expand Up @@ -93,12 +91,11 @@ func DecodeRevertReason(logs []*types.Log) []string {
for _, log := range logs {
_, reason, err := V1DecodeTxFailedEvent(log)
if err != nil {
_, reason, _, _ = V2DecodeTxFailedEvent(log)
_, reason, _, err = V2DecodeTxFailedEvent(log)
}
if err != nil {
_, reason, _, _ = V3DecodeTxFailedEvent(log)
_, reason, _, err = V3DecodeTxFailedEvent(log)
}

reasons = append(reasons, reason)
}
return reasons
Expand Down

0 comments on commit da76a14

Please sign in to comment.