symfony-docs
symfony-docs copied to clipboard
Adding that you cannot access a session inside a constructor
Please double-check! The info is taken from PhpStorm's Symfony Plugin: https://espend.de/phpstorm/plugin/symfony#inspections:
A Session must not be used inside a constructor
I think this should be explained here, since doing $this->session = $requestStack->getSession(); right in the constructor looked like a nice idea...