aboutsummaryrefslogtreecommitdiffstats
path: root/packages/0x.js/src/order_watcher/event_watcher.ts
diff options
context:
space:
mode:
Diffstat (limited to 'packages/0x.js/src/order_watcher/event_watcher.ts')
-rw-r--r--packages/0x.js/src/order_watcher/event_watcher.ts10
1 files changed, 4 insertions, 6 deletions
diff --git a/packages/0x.js/src/order_watcher/event_watcher.ts b/packages/0x.js/src/order_watcher/event_watcher.ts
index e67b93251..246ab8292 100644
--- a/packages/0x.js/src/order_watcher/event_watcher.ts
+++ b/packages/0x.js/src/order_watcher/event_watcher.ts
@@ -1,9 +1,7 @@
+import { BlockParamLiteral, LogEntry } from '@0xproject/types';
import { intervalUtils } from '@0xproject/utils';
import { Web3Wrapper } from '@0xproject/web3-wrapper';
import * as _ from 'lodash';
-import * as Web3 from 'web3';
-
-import { BlockParamLiteral } from '@0xproject/types';
import { EventWatcherCallback, ZeroExError } from '../types';
import { assert } from '../utils/assert';
@@ -23,7 +21,7 @@ export class EventWatcher {
private _web3Wrapper: Web3Wrapper;
private _pollingIntervalMs: number;
private _intervalIdIfExists?: NodeJS.Timer;
- private _lastEvents: Web3.LogEntry[] = [];
+ private _lastEvents: LogEntry[] = [];
constructor(web3Wrapper: Web3Wrapper, pollingIntervalIfExistsMs: undefined | number) {
this._web3Wrapper = web3Wrapper;
this._pollingIntervalMs = _.isUndefined(pollingIntervalIfExistsMs)
@@ -69,7 +67,7 @@ export class EventWatcher {
await this._emitDifferencesAsync(newEvents, LogEventState.Added, callback);
this._lastEvents = pendingEvents;
}
- private async _getEventsAsync(): Promise<Web3.LogEntry[]> {
+ private async _getEventsAsync(): Promise<LogEntry[]> {
const eventFilter = {
fromBlock: BlockParamLiteral.Pending,
toBlock: BlockParamLiteral.Pending,
@@ -78,7 +76,7 @@ export class EventWatcher {
return events;
}
private async _emitDifferencesAsync(
- logs: Web3.LogEntry[],
+ logs: LogEntry[],
logEventState: LogEventState,
callback: EventWatcherCallback,
): Promise<void> {