Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

Commit

Permalink
fix error setting headers after headers sent exception
Browse files Browse the repository at this point in the history
  • Loading branch information
Greg Guthe committed Aug 29, 2017
1 parent 60163ee commit 8281a5c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/src/middleware/csrf.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ exports.csrf = function(req, res, next) {
let exc = new Error("Duplicate CSRF cookies");
exc.headerValue = rawCookies;
captureRavenException(exc);
simpleResponse(res, "Bad request", 400);
return simpleResponse(res, "Bad request", 400);
}
req.cookies._csrf = req.cookies.get("_csrf"); // csurf expects a property
next();
Expand Down

0 comments on commit 8281a5c

Please # to comment.