Update website to use the new unsubscribeAll method in contract-wrappers

This commit is contained in:
Alex Browne
2018-10-15 18:04:29 -07:00
parent 2c63909d5d
commit 5509bf5aeb

View File

@@ -859,13 +859,12 @@ export class Blockchain {
shouldUserLedgerProvider,
);
if (!_.isUndefined(this._contractWrappers)) {
this._contractWrappers.setProvider(provider);
} else {
const contractWrappersConfig = {
networkId,
};
this._contractWrappers = new ContractWrappers(provider, contractWrappersConfig);
this._contractWrappers.unsubscribeAll();
}
const contractWrappersConfig = {
networkId,
};
this._contractWrappers = new ContractWrappers(provider, contractWrappersConfig);
if (!_.isUndefined(this._zeroEx)) {
this._zeroEx.setProvider(provider, networkId);
} else {