aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2017-10-26 19:03:39 +0800
committerFabio Berger <me@fabioberger.com>2017-10-31 00:49:16 +0800
commit02d470892f68abb5f92a9b79b4a581979288f2f3 (patch)
tree2969dae8be255ce054ebd9346da9d33a807ee683 /src
parent161f62dc27b95f214bfaf8dd38fa40e7a4910584 (diff)
downloaddexon-sol-tools-02d470892f68abb5f92a9b79b4a581979288f2f3.tar
dexon-sol-tools-02d470892f68abb5f92a9b79b4a581979288f2f3.tar.gz
dexon-sol-tools-02d470892f68abb5f92a9b79b4a581979288f2f3.tar.bz2
dexon-sol-tools-02d470892f68abb5f92a9b79b4a581979288f2f3.tar.lz
dexon-sol-tools-02d470892f68abb5f92a9b79b4a581979288f2f3.tar.xz
dexon-sol-tools-02d470892f68abb5f92a9b79b4a581979288f2f3.tar.zst
dexon-sol-tools-02d470892f68abb5f92a9b79b4a581979288f2f3.zip
Compare logs by string representation
Diffstat (limited to 'src')
-rw-r--r--src/mempool/mempool_watcher.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mempool/mempool_watcher.ts b/src/mempool/mempool_watcher.ts
index be598c28f..7a485172d 100644
--- a/src/mempool/mempool_watcher.ts
+++ b/src/mempool/mempool_watcher.ts
@@ -36,8 +36,8 @@ export class MempoolWatcher {
// that's why we just ignore those cases.
return;
}
- const removedEvents = _.differenceBy(this._lastMempoolEvents, pendingEvents, _.isEqual);
- const newEvents = _.differenceBy(pendingEvents, this._lastMempoolEvents, _.isEqual);
+ const removedEvents = _.differenceBy(this._lastMempoolEvents, pendingEvents, JSON.stringify);
+ const newEvents = _.differenceBy(pendingEvents, this._lastMempoolEvents, JSON.stringify);
let isRemoved = true;
this._emitDifferences(removedEvents, isRemoved);
isRemoved = false;