fix #209
Showing
1 changed file
with
1 additions
and
3 deletions
| ... | @@ -335,9 +335,7 @@ func (c *Controller) CheckXsrfCookie() bool { | ... | @@ -335,9 +335,7 @@ func (c *Controller) CheckXsrfCookie() bool { |
| 335 | } | 335 | } |
| 336 | if token == "" { | 336 | if token == "" { |
| 337 | c.Ctx.Abort(403, "'_xsrf' argument missing from POST") | 337 | c.Ctx.Abort(403, "'_xsrf' argument missing from POST") |
| 338 | } | 338 | } else if c._xsrf_token != token { |
| 339 | |||
| 340 | if c._xsrf_token != token { | ||
| 341 | c.Ctx.Abort(403, "XSRF cookie does not match POST argument") | 339 | c.Ctx.Abort(403, "XSRF cookie does not match POST argument") |
| 342 | } | 340 | } |
| 343 | return true | 341 | return true | ... | ... |
-
Please register or sign in to post a comment