Does not work with invokable controllers
Closed this issue · 1 comments
benr77 commented
I have discovered that the bundle does not work with invokable controller classes. https://symfony.com/doc/current/controller/service.html#invokable-controllers
The problem is that in AnnotationResolver
you are expecting $event->getController()
to return an array, whereas with you use __invoke()
for the controller method name, $event->getController()
actually returns the controller directly instead of it being wrapped in an array.
I will submit a PR in a moment