aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2017-12-06 12:15:23 +0800
committerFabio Berger <me@fabioberger.com>2017-12-06 12:15:23 +0800
commit5119e49e47fd848e7b0dca90683c8dfbdc9b8b90 (patch)
tree04fa533956c01030a547898a97c49dca1ef41462
parentcfb9f874180c95f396ffc5a40fc508584c344802 (diff)
downloaddexon-sol-tools-5119e49e47fd848e7b0dca90683c8dfbdc9b8b90.tar
dexon-sol-tools-5119e49e47fd848e7b0dca90683c8dfbdc9b8b90.tar.gz
dexon-sol-tools-5119e49e47fd848e7b0dca90683c8dfbdc9b8b90.tar.bz2
dexon-sol-tools-5119e49e47fd848e7b0dca90683c8dfbdc9b8b90.tar.lz
dexon-sol-tools-5119e49e47fd848e7b0dca90683c8dfbdc9b8b90.tar.xz
dexon-sol-tools-5119e49e47fd848e7b0dca90683c8dfbdc9b8b90.tar.zst
dexon-sol-tools-5119e49e47fd848e7b0dca90683c8dfbdc9b8b90.zip
Move declaration into proper conditional block
-rw-r--r--packages/website/ts/blockchain.ts2
1 files changed, 1 insertions, 1 deletions
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<LogFillContractEventArgs>) => {
- 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
}