New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Controllers can't be found inside a route group #239
Comments
Yeh, groups don't inherit in lumen, so you need to define the namespace over and over inside nested groups. |
Won't this be fixed? |
I also ran into this. It is not intuitive that this is the case and feels like a bug. At very least the documentation needs to be updated to mention this (if it is already mentioned, it needs mentioning again on the routes page). It is especially confusing as the namespace is set in app.php, so it isn't obvious that routes.php is actually already within a group unless you've dived a bit deeper into how things work. |
I also feel that this needs to be better documented. This example here suggests that namespaces are inherited and a developer should "register controller routes without specifying the full I'm defining an additional group in |
1 similar comment
@bogdanghervan +1 |
What's the resolution for this? its become unintuitive |
@geocine looks like this was fixed, can you close this issue? |
Eg. This will throw an error Class ServicesController does not exist
To be able to fix this I must explicitly define the namespace
This should not be the case because this is already defined by default on the bootstrap\app.php
The text was updated successfully, but these errors were encountered: