Skip to content

Commit 8afbb25

Browse files
kucebflotwig
andcommitted
fix: fix infinite recursion during some redirects (#2)
Co-authored-by: Zach Bloomquist <[email protected]>
1 parent 2ccf237 commit 8afbb25

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

request.js

+1
Original file line numberDiff line numberDiff line change
@@ -991,6 +991,7 @@ Request.prototype.onRequestResponse = function (response) {
991991
// Hack to emit end on close because of a core bug that never fires end
992992
response.on('close', function () {
993993
if (!self._ended) {
994+
self._ended = true
994995
self.response.emit('end')
995996
}
996997
})

0 commit comments

Comments
 (0)