Merge pull request #712 from edy-b/issue-707
Don't set cached cookies, fixes issue #707pull/709/merge
commit
1043d607d0
|
@ -73,6 +73,9 @@ CachingMiddleware.prototype = new function () {
|
||||||
var _headers = {};
|
var _headers = {};
|
||||||
old_res.setHeader = res.setHeader;
|
old_res.setHeader = res.setHeader;
|
||||||
res.setHeader = function (key, value) {
|
res.setHeader = function (key, value) {
|
||||||
|
// Don't set cookies, see issue #707
|
||||||
|
if (key.toLowerCase() === 'set-cookie') return;
|
||||||
|
|
||||||
_headers[key.toLowerCase()] = value;
|
_headers[key.toLowerCase()] = value;
|
||||||
old_res.setHeader.call(res, key, value);
|
old_res.setHeader.call(res, key, value);
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue