Skip to content

Commit e45516d

Browse files
authored
Bugfix - when using AbortController, errors on resulting stream must be caught (webtorrent#539)
* use-native-fetch * Bugfix: `res.body` should handle errors according to nodejs/undici#3353 (comment) * Revert "use-native-fetch" This reverts commit d654603. * fix-quotes * some-build-targets-return-different-output
1 parent f2f4990 commit e45516d

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/client/http-tracker.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -150,6 +150,7 @@ class HTTPTracker extends Tracker {
150150
'user-agent': this.client._userAgent || ''
151151
}
152152
})
153+
if (res.body.on) res.body.on('error', cb)
153154
} catch (err) {
154155
if (err) return cb(err)
155156
}

0 commit comments

Comments
 (0)