aboutsummaryrefslogtreecommitdiffstats
path: root/packages/contract_templates/partials
diff options
context:
space:
mode:
Diffstat (limited to 'packages/contract_templates/partials')
-rw-r--r--packages/contract_templates/partials/callAsync.handlebars1
1 files changed, 1 insertions, 0 deletions
diff --git a/packages/contract_templates/partials/callAsync.handlebars b/packages/contract_templates/partials/callAsync.handlebars
index dd1b90212..ddbbe7508 100644
--- a/packages/contract_templates/partials/callAsync.handlebars
+++ b/packages/contract_templates/partials/callAsync.handlebars
@@ -19,6 +19,7 @@ async callAsync(
self._web3Wrapper.getContractDefaults(),
);
const rawCallResult = await self._web3Wrapper.callAsync(callDataWithDefaults, defaultBlock);
+ BaseContract._throwIfRevertWithReasonCallResult(rawCallResult);
let resultArray = ethersFunction.decode(rawCallResult);
const outputAbi = (_.find(self.abi, {name: '{{this.name}}'}) as MethodAbi).outputs;
resultArray = BaseContract._formatABIDataItemList(outputAbi, resultArray, BaseContract._lowercaseAddress.bind(this));