update params
Showing
1 changed file
with
2 additions
and
0 deletions
| ... | @@ -261,6 +261,7 @@ func (p *ControllerRegistor) ServeHTTP(rw http.ResponseWriter, r *http.Request) | ... | @@ -261,6 +261,7 @@ func (p *ControllerRegistor) ServeHTTP(rw http.ResponseWriter, r *http.Request) |
| 261 | values := r.URL.Query() | 261 | values := r.URL.Query() |
| 262 | for i, match := range matches[1:] { | 262 | for i, match := range matches[1:] { |
| 263 | values.Add(c.params[i], match) | 263 | values.Add(c.params[i], match) |
| 264 | r.Form.Add(c.params[i], match) | ||
| 264 | params[c.params[i]] = match | 265 | params[c.params[i]] = match |
| 265 | } | 266 | } |
| 266 | //reassemble query params and add to RawQuery | 267 | //reassemble query params and add to RawQuery |
| ... | @@ -315,6 +316,7 @@ func (p *ControllerRegistor) ServeHTTP(rw http.ResponseWriter, r *http.Request) | ... | @@ -315,6 +316,7 @@ func (p *ControllerRegistor) ServeHTTP(rw http.ResponseWriter, r *http.Request) |
| 315 | values := r.URL.Query() | 316 | values := r.URL.Query() |
| 316 | for i, match := range matches[1:] { | 317 | for i, match := range matches[1:] { |
| 317 | values.Add(route.params[i], match) | 318 | values.Add(route.params[i], match) |
| 319 | r.Form.Add(route.params[i], match) | ||
| 318 | params[route.params[i]] = match | 320 | params[route.params[i]] = match |
| 319 | } | 321 | } |
| 320 | //reassemble query params and add to RawQuery | 322 | //reassemble query params and add to RawQuery | ... | ... |
-
Please register or sign in to post a comment