-
-
Notifications
You must be signed in to change notification settings - Fork 993
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
URLParam need to check is nil or not #426
Comments
meet same problem |
yes URLParams.Keys existed but URLParams.values not
if web get request '/url//test' that missing url param, URLParams.values will panic because no value in there.
|
I was only able to reproduce this panic when using a regexp param. A regular param (like the OP) doesn't trigger a panic for me. I've pushed a PR that adds a failing test. |
thanks for the report + suggestions -- fixed: 3658d98 |
the route like below,
and post request as localhost:8080/api/v1/cps/sessions//operate, then in function
x.URLParams.Values is nil , but k ==0 , use x.URLParams.Values[0] panic occurs.
The text was updated successfully, but these errors were encountered: