We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 04b147f commit aee16abCopy full SHA for aee16ab
libs/remix-simulator/src/methods/transactions.ts
@@ -143,9 +143,12 @@ export class Transactions {
143
return cb('revert ' + reason)
144
} catch (e) {
145
return cb(e.message)
146
- }
+ }
147
148
+ let gasUsed = result.result.execResult.gasUsed.toNumber()
149
+ if (result.result.execResult.gasRefund) {
150
+ gasUsed += result.result.execResult.gasRefund.toNumber()
151
}
- const gasUsed = result.result.execResult.gasUsed.toNumber()
152
cb(null, Math.ceil(gasUsed + (15 * gasUsed) / 100))
153
})
154
0 commit comments