Closed ocramz closed 11 months ago
Nice to see these changes coming to scotty !
If I may add a comment, I'm not sure it makes sense to call next
when parseParam
fails for query and form parameters. I believe it would provide better errors to just return a "bad request" in these cases.
Nice to see these changes coming to scotty ! If I may add a comment, I'm not sure it makes sense to call
next
whenparseParam
fails for query and form parameters. I believe it would provide better errors to just return a "bad request" in these cases.
@jfraudeau Could you share a permalink to where is this behaviour implemented? Thank you
@jfraudeau Good catch! But applying your suggestion would be a user-visible change, even though I don't know whether anybody actually relied on the current (buggy) behaviour or they simply worked around it.
@ocramz I think it should be ok if the change only applies to the new formParams and queryParams
I took a stab at it and added a few tests, @jfraudeau please take another look when you have time. Thanks!
Disambiguate request parameters (#204).
Env
type to have three [Param] fields instead of onecaptureParam
,formParam
,queryParam
and the associatedcaptureParams
,formParams
,queryParams
.param
andparams