From 51319e9fe513893f71d59895b374d42d60030022 Mon Sep 17 00:00:00 2001 From: yann300 Date: Mon, 27 Feb 2023 11:54:10 +0100 Subject: [PATCH] fix using compareByteCode --- apps/remix-ide/src/app/tabs/debugger-tab.js | 4 ---- libs/remix-core-plugin/src/lib/compiler-fetch-and-compile.ts | 3 +-- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/apps/remix-ide/src/app/tabs/debugger-tab.js b/apps/remix-ide/src/app/tabs/debugger-tab.js index 8d357acc65..2d49dcc6c7 100644 --- a/apps/remix-ide/src/app/tabs/debugger-tab.js +++ b/apps/remix-ide/src/app/tabs/debugger-tab.js @@ -45,10 +45,6 @@ export class DebuggerTab extends DebuggerApiMixin(ViewPlugin) { this.call('notification', 'toast', notFoundToastMsg(contractAddress)) }) - this.on('fetchAndCompile', 'usingLocalCompilation', (contractAddress) => { - this.call('notification', 'toast', localCompilationToastMsg()) - }) - this.on('fetchAndCompile', 'sourceVerificationNotAvailable', () => { this.call('notification', 'toast', sourceVerificationNotAvailableToastMsg()) }) diff --git a/libs/remix-core-plugin/src/lib/compiler-fetch-and-compile.ts b/libs/remix-core-plugin/src/lib/compiler-fetch-and-compile.ts index ed53f4fea0..810faadd2c 100644 --- a/libs/remix-core-plugin/src/lib/compiler-fetch-and-compile.ts +++ b/libs/remix-core-plugin/src/lib/compiler-fetch-and-compile.ts @@ -100,12 +100,11 @@ export class FetchAndCompile extends Plugin { if (compilation) { let found = false compilation.visitContracts((contract) => { - found = util.compareByteCode('0x' + contract.object.evm.deployedBytecode.object, codeAtAddress) + found = util.compareByteCode(codeAtAddress, '0x' + contract.object.evm.deployedBytecode.object) return found }) if (found) { await this.call('compilerArtefacts', 'addResolvedContract', contractAddress, compilation) - setTimeout(_ => this.emit('usingLocalCompilation', contractAddress), 0) return compilation } }