Update txExecution.ts

pull/4177/head
Aniket 1 year ago
parent a1e3fce5af
commit 2491b719f1
  1. 4
      libs/remix-lib/src/execution/txExecution.ts

@ -82,7 +82,7 @@ export function checkError (execResult, compiledContracts) {
const exceptionError = execResult.errorMessage || ''
const error = `Error occured: ${execResult.errorMessage}.\n`
let msg = ''
if (exceptionError === errorCode.INVALID_OPCODE) {
if (exceptionError.includes(errorCode.INVALID_OPCODE)) {
msg = '\t\n\tThe execution might have thrown OR the EVM version used by the selected environment is not compatible with the compiler EVM version.\n'
ret.error = true
} else if (exceptionError === errorCode.OUT_OF_GAS) {
@ -173,4 +173,4 @@ export function checkError (execResult, compiledContracts) {
}
ret.message = `${error}\n${exceptionError}\n${msg}\nDebug the transaction to get more information.`
return ret
}
}

Loading…
Cancel
Save