1
0
mirror of https://github.com/astaxie/beego.git synced 2025-06-11 20:20:39 +00:00

Merge pull request #1805 from JessonChan/abort_panic_bug

Abort panic bug
This commit is contained in:
astaxie
2016-03-23 10:22:32 +08:00
5 changed files with 207 additions and 135 deletions

View File

@ -77,6 +77,7 @@ func (ctx *Context) Redirect(status int, localurl string) {
// Abort stops this request.
// if beego.ErrorMaps exists, panic body.
func (ctx *Context) Abort(status int, body string) {
ctx.Output.SetStatus(status)
panic(body)
}