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,9 +195,11 @@ RoutingProxy.prototype.proxyRequest = function (req, res, options) {
|
|||||||
//
|
//
|
||||||
if (!location) {
|
if (!location) {
|
||||||
try {
|
try {
|
||||||
|
if (!this.emit('notFound', req, res)) {
|
||||||
res.writeHead(404);
|
res.writeHead(404);
|
||||||
res.end();
|
res.end();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
catch (er) {
|
catch (er) {
|
||||||
console.error("res.writeHead/res.end error: %s", er.message);
|
console.error("res.writeHead/res.end error: %s", er.message);
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user