Skip to content

Commit

Permalink
Merge pull request #1887 from gnosis/gh-1886/fix-tx-check
Browse files Browse the repository at this point in the history
gh-1886 Only check when there's something returned from the call
  • Loading branch information
Dmitry Bespalov authored Feb 4, 2022
2 parents 180fd9d + 22ef84d commit 364eb46
Showing 1 changed file with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -214,9 +214,11 @@ class TransactionExecutionController {
gas = try partialResults.gas.get()

let execTransactionSuccess = try partialResults.ethCall.get()
let success = try Sol.Bool(execTransactionSuccess).storage
guard success else {
throw TransactionExecutionError(code: -7, message: "Internal Gnosis Safe transaction fails. Please double check whether this transaction is valid with the current state of the Safe.")
if !execTransactionSuccess.isEmpty {
let success = try Sol.Bool(execTransactionSuccess).storage
guard success else {
throw TransactionExecutionError(code: -7, message: "Internal Gnosis Safe transaction fails. Please double check whether this transaction is valid with the current state of the Safe.")
}
}
} catch {
errors.append(error)
Expand Down

0 comments on commit 364eb46

Please sign in to comment.