fix dumping the storage

pull/5370/head
yann300 2 years ago committed by Aniket
parent c6ece83a2f
commit 734b12f54e
  1. 10
      libs/remix-simulator/src/VmProxy.ts

@ -255,10 +255,12 @@ export class VmProxy {
this.processingAddress = normalizeHexAddress(step.stack[step.stack.length - 2]) this.processingAddress = normalizeHexAddress(step.stack[step.stack.length - 2])
this.processingAddress = toChecksumAddress(this.processingAddress) this.processingAddress = toChecksumAddress(this.processingAddress)
if (!this.storageCache[this.processingHash][this.processingAddress]) { if (!this.storageCache[this.processingHash][this.processingAddress]) {
const account = Address.fromString(this.processingAddress) ((processingHash, processingAddress, self) => {
this.vm.stateManager.dumpStorage(account).then((storage) => { const account = Address.fromString(processingAddress)
this.storageCache[this.processingHash][this.processingAddress] = storage self.vm.stateManager.dumpStorage(account).then((storage) => {
}).catch(console.log) self.storageCache[processingHash][processingAddress] = storage
}).catch(console.log)
})(this.processingHash, this.processingAddress, this)
} }
} }
} }

Loading…
Cancel
Save