From 5119e49e47fd848e7b0dca90683c8dfbdc9b8b90 Mon Sep 17 00:00:00 2001 From: Fabio Berger Date: Tue, 5 Dec 2017 22:15:23 -0600 Subject: Move declaration into proper conditional block --- packages/website/ts/blockchain.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/website/ts/blockchain.ts b/packages/website/ts/blockchain.ts index c32984477..f11c014fb 100644 --- a/packages/website/ts/blockchain.ts +++ b/packages/website/ts/blockchain.ts @@ -511,7 +511,6 @@ export class Blockchain { const subscriptionId = this.zeroEx.exchange.subscribe( ExchangeEvents.LogFill, indexFilterValues, async (err: Error, decodedLogEvent: DecodedLogEvent) => { - const decodedLog = decodedLogEvent.log; if (err) { // Note: it's not entirely clear from the documentation which // errors will be thrown by `watch`. For now, let's log the error @@ -522,6 +521,7 @@ export class Blockchain { this.stopWatchingExchangeLogFillEventsAsync(); // fire and forget return; } else { + const decodedLog = decodedLogEvent.log; if (!this.doesLogEventInvolveUser(decodedLog)) { return; // We aren't interested in the fill event } -- cgit v1.2.3