This is not a question about changing or preprocessing the twig template of the 403 page.
I have a controller with an
access function called by the
_custom_access key of my route.
In some circumstance, this function is returning
AccessResult::forbidden("a good reason"); which lead to my default
Most of the case, this is the behavior I would like to have, but in few cases, I would like to have another title and another message for this page like “You can not access because you eat too much chocolate”
Should I create a new custom error route and send a new response to this route from my
access function? (hint: I tried without success)