Skip to content

Commit

Permalink
respond with 202 Accepted when forwarding
Browse files Browse the repository at this point in the history
  • Loading branch information
gravyTrainee authored and gravyTrainee committed Sep 3, 2021
1 parent 20ed22c commit e22c8df
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lib/http-proxy/passes/web-incoming.js
Expand Up @@ -122,7 +122,10 @@ module.exports = {

(options.buffer || req).pipe(forwardReq);
}
if(!options.target) { return res.end(); }
if(!options.target) {
res.statusCode = 202;
return res.end(http.STATUS_CODES[res.statusCode]);
}
}

// Request initalization
Expand Down

0 comments on commit e22c8df

Please sign in to comment.