Category: symfony-eventdispatcher

Symfony onKernelRequest headers->set dont received on @Route

I have functionm onKernelRequest when i want to add some custom header(in my case api=true||$request->headers->set(‘api’, “true”)) and in all Request $request i can get that header but when i try it on annotation its fail: onKernelRequest: public function onKernelRequest(RequestEvent $event)…