We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 48ad0d3 commit d723d36Copy full SHA for d723d36
lib/transports/http.js
@@ -42,6 +42,10 @@ HTTPTransport.prototype.__proto__ = Transport.prototype;
42
*/
43
44
HTTPTransport.prototype.handleRequest = function (req) {
45
+
46
+ // Always set the response in case an error is returned to the client
47
+ this.response = req.res;
48
49
if (req.method == 'POST') {
50
var buffer = ''
51
, res = req.res
@@ -77,8 +81,6 @@ HTTPTransport.prototype.handleRequest = function (req) {
77
81
headers['Access-Control-Allow-Credentials'] = 'true';
78
82
}
79
83
} else {
80
- this.response = req.res;
-
84
Transport.prototype.handleRequest.call(this, req);
85
86
};
0 commit comments