diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/0x.ts | 1 | ||||
-rw-r--r-- | src/contract_wrappers/ether_token_wrapper.ts | 3 |
2 files changed, 4 insertions, 0 deletions
@@ -172,6 +172,7 @@ export class ZeroEx { (this.tokenRegistry as any)._invalidateContractInstance(); await (this.token as any)._invalidateContractInstancesAsync(); (this.proxy as any)._invalidateContractInstance(); + (this.etherToken as any)._invalidateContractInstance(); } /** * Get user Ethereum addresses available through the supplied web3 instance available for sending transactions. diff --git a/src/contract_wrappers/ether_token_wrapper.ts b/src/contract_wrappers/ether_token_wrapper.ts index 76e7289b7..03d714bd7 100644 --- a/src/contract_wrappers/ether_token_wrapper.ts +++ b/src/contract_wrappers/ether_token_wrapper.ts @@ -64,6 +64,9 @@ export class EtherTokenWrapper extends ContractWrapper { const wethContract = await this._getEtherTokenContractAsync(); return wethContract.address; } + private _invalidateContractInstance(): void { + delete this._etherTokenContractIfExists; + } private async _getEtherTokenContractAsync(): Promise<EtherTokenContract> { if (!_.isUndefined(this._etherTokenContractIfExists)) { return this._etherTokenContractIfExists; |