MCPcopy
hub / github.com/wuchangming/spy-debugger / responseHandler

Method responseHandler

src/proxy/SpyProxy.js:76–84  ·  view source on GitHub ↗
(rOptions, req, res, responseCallback)

Source from the content-addressed store, hash-verified

74
75 }
76 responseHandler(rOptions, req, res, responseCallback) {
77 return new http.ClientRequest(rOptions, (proxyRes) => {
78 if (responseCallback) {
79 responseCallback(req, res,proxyRes);
80 } else {
81 this.interceptResponse(req, res, proxyRes);
82 }
83 });
84 }
85 ignoreResponse(req, res, proxyRes) {
86 Object.keys(proxyRes.headers).forEach(function(key) {
87 if(proxyRes.headers[key] != undefined){

Callers 2

requestHandlerMethod · 0.95
SpyProxy.jsFile · 0.80

Calls 1

interceptResponseMethod · 0.95

Tested by

no test coverage detected