Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/webtorrent/webtorrent.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorFeross Aboukhadijeh <feross@feross.org>2021-01-27 00:55:56 +0300
committerFeross Aboukhadijeh <feross@feross.org>2021-01-27 00:55:56 +0300
commita6f287104d4198479d74e7c27695c9fc7b744c93 (patch)
tree52a64f8913ec03a5cdeeee4edfa2b989655dd139 /lib
parent6fd348689d416360bca1405f696c015f77cce835 (diff)
fix queuemicrotask usage
Diffstat (limited to 'lib')
-rw-r--r--lib/torrent.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/torrent.js b/lib/torrent.js
index 201a452..abb3b31 100644
--- a/lib/torrent.js
+++ b/lib/torrent.js
@@ -587,7 +587,7 @@ class Torrent extends EventEmitter {
this.store.get(index, (err, buf) => {
if (this.destroyed) return cb(new Error('torrent is destroyed'))
- if (err) return queueMicrotask(cb, null) // ignore error
+ if (err) return queueMicrotask(() => cb(null)) // ignore error
sha1(buf, hash => {
if (this.destroyed) return cb(new Error('torrent is destroyed'))