aboutsummaryrefslogtreecommitdiffstats
path: root/packages/0x.js
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2017-11-21 02:49:55 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2017-11-21 02:49:55 +0800
commitc068ec5231a97752a914eaa0479750c05b5c6342 (patch)
tree5601f25f2aec13265a2b293956a188b1cb2f9c3b /packages/0x.js
parent86d19657b14f7ac7afcb04ae952425f094a02b14 (diff)
downloaddexon-sol-tools-c068ec5231a97752a914eaa0479750c05b5c6342.tar
dexon-sol-tools-c068ec5231a97752a914eaa0479750c05b5c6342.tar.gz
dexon-sol-tools-c068ec5231a97752a914eaa0479750c05b5c6342.tar.bz2
dexon-sol-tools-c068ec5231a97752a914eaa0479750c05b5c6342.tar.lz
dexon-sol-tools-c068ec5231a97752a914eaa0479750c05b5c6342.tar.xz
dexon-sol-tools-c068ec5231a97752a914eaa0479750c05b5c6342.tar.zst
dexon-sol-tools-c068ec5231a97752a914eaa0479750c05b5c6342.zip
Add ifExists suffix
Diffstat (limited to 'packages/0x.js')
-rw-r--r--packages/0x.js/src/order_watcher/expiration_watcher.ts4
-rw-r--r--packages/0x.js/src/order_watcher/order_state_watcher.ts8
2 files changed, 6 insertions, 6 deletions
diff --git a/packages/0x.js/src/order_watcher/expiration_watcher.ts b/packages/0x.js/src/order_watcher/expiration_watcher.ts
index d699b7a51..cf0222e3c 100644
--- a/packages/0x.js/src/order_watcher/expiration_watcher.ts
+++ b/packages/0x.js/src/order_watcher/expiration_watcher.ts
@@ -18,8 +18,8 @@ export class ExpirationWatcher {
private callbackIfExists?: (orderHash: string) => void;
private orderExpirationCheckingIntervalMs: number;
private orderExpirationCheckingIntervalIdIfExists?: NodeJS.Timer;
- constructor(orderExpirationCheckingIntervalMs?: number) {
- this.orderExpirationCheckingIntervalMs = orderExpirationCheckingIntervalMs ||
+ constructor(orderExpirationCheckingIntervalMsIfExists?: number) {
+ this.orderExpirationCheckingIntervalMs = orderExpirationCheckingIntervalMsIfExists ||
DEFAULT_ORDER_EXPIRATION_CHECKING_INTERVAL_MS;
const scoreFunction = (orderHash: string) => this.expiration[orderHash].toNumber();
this.orderHashHeapByExpiration = new Heap(scoreFunction);
diff --git a/packages/0x.js/src/order_watcher/order_state_watcher.ts b/packages/0x.js/src/order_watcher/order_state_watcher.ts
index bc61e415c..40007805f 100644
--- a/packages/0x.js/src/order_watcher/order_state_watcher.ts
+++ b/packages/0x.js/src/order_watcher/order_state_watcher.ts
@@ -74,10 +74,10 @@ export class OrderStateWatcher {
this._orderStateUtils = new OrderStateUtils(
this._balanceAndProxyAllowanceLazyStore, this._orderFilledCancelledLazyStore,
);
- const orderExpirationCheckingIntervalMs = _.isUndefined(config) ?
- undefined :
- config.orderExpirationCheckingIntervalMs;
- this._expirationWatcher = new ExpirationWatcher(orderExpirationCheckingIntervalMs);
+ const orderExpirationCheckingIntervalMsIfExists = _.isUndefined(config) ?
+ undefined :
+ config.orderExpirationCheckingIntervalMs;
+ this._expirationWatcher = new ExpirationWatcher(orderExpirationCheckingIntervalMsIfExists);
}
/**
* Add an order to the orderStateWatcher. Before the order is added, it's