mirror of
https://github.com/http-party/node-http-proxy.git
synced 2025-12-08 20:59:18 +00:00
This commit is contained in:
parent
4c1a2c1416
commit
3130665d9f
@ -195,8 +195,10 @@ RoutingProxy.prototype.proxyRequest = function (req, res, options) {
|
||||
//
|
||||
if (!location) {
|
||||
try {
|
||||
res.writeHead(404);
|
||||
res.end();
|
||||
if (!this.emit('notFound', req, res)) {
|
||||
res.writeHead(404);
|
||||
res.end();
|
||||
}
|
||||
}
|
||||
catch (er) {
|
||||
console.error("res.writeHead/res.end error: %s", er.message);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user