-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Route action and controller parameter inconsistencies #13555
Comments
That's why I prefer to use MicroCollection - define everything manually. $adminRoutes->get('/deconnexion', 'logout', 'admin_logout'); |
@stamster nonetheless, the fact that framework treats those two differently is an issue :) |
Personally, I do not think it's a problem. The controller is transformed because you have to use the PSR-4. It's up to the developer to do it right in my opinion. |
@Ark4ne the two are closely related, so if we use one case for controller, we should stick with it when it comes to the action as well, regardless of the lack of the standard for the action. Standards exist so that code we write is compatible and predictable. The lack of it doesn't mean we should stop caring. Having controller and action use two completely different cases introduces unexpected behavior, especially since it's not clearly mentioned in the docs. But I could delete my whole answer and just say consistency. |
Not going to be fixed/addressed in Thank you @scrnjakovic |
Nope, thank you @niden. |
@scrnjakovic If i get this right you want the framework to call your controller you can't use underscores in Namespaces or classnames. They must be CamelCase with no seperations between words. Also @Ark4ne PSR-1 4.3 enforces method naming conventions to lowerCamelCase. The only bug is that the action does not get transformed to myAction @niden. |
@JABirchall as @scrnjakovic said, the problem is the different behaviour. |
Resolved |
The text was updated successfully, but these errors were encountered: