-
Notifications
You must be signed in to change notification settings - Fork 1
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
Support unmarshalling handler parameters #47
Conversation
@@ -47,30 +47,30 @@ public function name() { | |||
* Returns a map of named sources to read arguments from request. Lazily | |||
* initialized on first use. | |||
* | |||
* @return [:(function(web.Request, string): var)] | |||
* @return [:web.frontend.Parameter] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This Parameter class is invokeable, thus old code relying on being to use $param($request, $name)
to read the parameter's value will continue to work!
Released in https://github.com/xp-forge/frontend/releases/tag/v6.0.0 🎄 |
Compatibility release https://github.com/xp-forge/handlebars-templates/releases/tag/v3.2.0 🎄 |
Example:
This would previously raise the following error: Argument 1 ($id) must be of type com\example\ObjectId, string given. This pull request makes this library behave consistently with https://github.com/xp-forge/rest-api