diff --git a/js/src/ui/MethodDecoding/methodDecodingStore.js b/js/src/ui/MethodDecoding/methodDecodingStore.js index 01f3a635c..d492aabee 100644 --- a/js/src/ui/MethodDecoding/methodDecodingStore.js +++ b/js/src/ui/MethodDecoding/methodDecodingStore.js @@ -55,9 +55,19 @@ export default class MethodDecodingStore { } loadFromAbi (_abi, contractAddress) { - const abi = new Abi(_abi); + let abi; - if (contractAddress && abi) { + try { + abi = new Abi(_abi); + } catch (error) { + console.warn('loadFromAbi', error, _abi); + } + + if (!abi) { + return; + } + + if (contractAddress) { this._contractsAbi[contractAddress] = abi; }