Information Security with HelmetJS - Hide Potentially Dangerous Information Using helmet.hidePoweredBy()

Tell us what’s happening:

I keep on getting the same issue with the code where it says

“helmet.hidePoweredBy() middleware should be mounted correctly”

I have tried a few different things and can’t seem to get it to work

Your project link(s)

solution: https://free-code-camp-security.herokuapp.com

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/103.0.0.0 Safari/537.36

Challenge: Information Security with HelmetJS - Hide Potentially Dangerous Information Using helmet.hidePoweredBy()

Link to the challenge:

We can’t see your code but make sure you added the exact version of helmet that is asked for in the initial challenge 3.21.3

Also, I’m not sure why but the route used for the test is returning Internal Server Error

https://free-code-camp-security.herokuapp.com/_api/app-info

It should be returning a JSON response like this.

{
  "headers": {
    "x-powered-by": "Express"
},
  "appStack": [
    "hidePoweredBy"
  ]
}

You didn’t remove any of the starting code from myApp.js did you? It should have some stuff at the bottom of that file that you need to keep.