mirror of
https://github.com/http-party/node-http-proxy.git
synced 2025-12-08 20:59:18 +00:00
[feature] add emit proxyRes
This commit is contained in:
parent
8085178dc2
commit
dda6f7a45a
@ -117,6 +117,7 @@ web_o = Object.keys(web_o).map(function(pass) {
|
||||
(options.buffer || req).pipe(proxyReq);
|
||||
|
||||
proxyReq.on('response', function(proxyRes) {
|
||||
server.emit('proxyRes', proxyRes);
|
||||
for(var i=0; i < web_o.length; i++) {
|
||||
if(web_o[i](req, res, proxyRes)) { break; }
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user