diff --git a/apps/remix-ide/src/app/tabs/web3-provider.js b/apps/remix-ide/src/app/tabs/web3-provider.js index b0acaefda9..1cac3b3c6c 100644 --- a/apps/remix-ide/src/app/tabs/web3-provider.js +++ b/apps/remix-ide/src/app/tabs/web3-provider.js @@ -31,7 +31,7 @@ export class Web3ProviderModule extends Plugin { provider[provider.sendAsync ? 'sendAsync' : 'send'](payload, async (error, message) => { if (error) { // Handle 'The method "debug_traceTransaction" does not exist / is not available.' error - if(error.code && error.code === -32601) { + if(error.message && error.code && error.code === -32601) { this.call('terminal', 'log', { value: error.message, type: 'error' } ) return reject(error.message) } else {