Skip to content

Commit 0d5a178

Browse files
committed
fix: onError is always called with error
1 parent d9bf886 commit 0d5a178

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ function impl (req, resOrSocket, headOrNil, {
4747
}, onProxyError) {
4848
let hasError = false
4949

50-
function onError (err, statusCode = (err && err.statusCode) || 500) {
50+
function onError (err, statusCode = err.statusCode || 500) {
5151
if (hasError) {
5252
return
5353
}

0 commit comments

Comments
 (0)