1
0
Fork 0
forked from svrjs/svrjs

Change reqerrhandler placeholder to emitting clientError event on the server.

This commit is contained in:
Dorian Niemiec 2024-08-25 10:57:37 +02:00
parent 478c3002f0
commit 0085ff740d

View file

@ -100,8 +100,8 @@ module.exports = (req, res, logFacilities, config, next) => {
'Either ":path" or ":method" pseudoheader is missing.',
);
if (Buffer.alloc) err.rawPacket = Buffer.alloc(0);
return;
// TODO: reqerrhandler(err, req.socket, fromMain);
if (req.socket && req.socket.server)
req.socket.server.emit("clientError", err, req.socket);
}
}