You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I added helmet to my connect-based app and having an issue with it:
TypeError: Object #<ServerResponse> has no method 'header'
at Object.handle (/.../helmet/lib/middleware/csp.js:26:17)
at next (/.../node_modules/connect/lib/proto.js:193:15)
For a quick fix, replace header( by setHeader( in /.../helmet/lib/middleware/csp.js. Or better, do an npm update to make sure that you have Helmet v0.1.3.
Hope this helps.
"make sure that you have Helmet v0.1.3." -helped not, and manually edit the helmet file would make any deploy not properly maintainable but by adding the following middleware would do the magic:
Hello,
I added helmet to my connect-based app and having an issue with it:
My configuration:
Any help is much appreciated.
The text was updated successfully, but these errors were encountered: