Title: Fatal Error when Enabling Security Headers
Last modified: October 25, 2021

---

# Fatal Error when Enabling Security Headers

 *  [unknownwp](https://wordpress.org/support/users/unknownwp/)
 * (@unknownwp)
 * [4 years, 7 months ago](https://wordpress.org/support/topic/fatal-error-when-enabling-security-headers/)
 * When trying to enable security headers I receive an error message stating:
 * “Fatal error: Uncaught Error: Call to a member function switch_to_locale() on
   null in”
 * there are 19 file paths listed after the error message on line 1666. Are all 
   of the file paths listed causing the headers not to be set?

The topic ‘Fatal Error when Enabling Security Headers’ is closed to new replies.

 * ![](https://ps.w.org/http-headers/assets/icon-128x128.png?rev=1413576)
 * [HTTP Headers](https://wordpress.org/plugins/http-headers/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/http-headers/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/http-headers/)
 * [Active Topics](https://wordpress.org/support/plugin/http-headers/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/http-headers/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/http-headers/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [unknownwp](https://wordpress.org/support/users/unknownwp/)
 * Last activity: [4 years, 7 months ago](https://wordpress.org/support/topic/fatal-error-when-enabling-security-headers/)
 * Status: not resolved