Skip to main content
2 of 3
replaced http://drupal.stackexchange.com/ with https://drupal.stackexchange.com/

The simplest method is to write a custom EventSubscriber which removes the header

$response->headers->remove('X-Generator');

like in this example

https://drupal.stackexchange.com/a/201297/47547

where you need to replace this line only.

4uk4
  • 101.7k
  • 7
  • 173
  • 217