diff options
author | Unknwon <u@gogs.io> | 2017-03-16 17:18:43 -0400 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2017-03-16 17:18:43 -0400 |
commit | 0ccd7c97abcb1ae314c9c17b0c08863cb13115fa (patch) | |
tree | d5314ef88257d64b3749194c024ca853486f799e /routers/user/setting.go | |
parent | 4e64e71e28dcfb9ef41d7cbc63ff1474ad8e5126 (diff) |
models: rename ErrUserNotExist -> errors.UserNotExist
Diffstat (limited to 'routers/user/setting.go')
-rw-r--r-- | routers/user/setting.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/routers/user/setting.go b/routers/user/setting.go index 0ea00770..c2c273c2 100644 --- a/routers/user/setting.go +++ b/routers/user/setting.go @@ -5,7 +5,6 @@ package user import ( - "errors" "fmt" "io/ioutil" "strings" @@ -14,6 +13,7 @@ import ( log "gopkg.in/clog.v1" "github.com/gogits/gogs/models" + "github.com/gogits/gogs/models/errors" "github.com/gogits/gogs/modules/base" "github.com/gogits/gogs/modules/context" "github.com/gogits/gogs/modules/form" @@ -456,7 +456,7 @@ func SettingsDelete(ctx *context.Context) { if ctx.Req.Method == "POST" { if _, err := models.UserSignIn(ctx.User.Name, ctx.Query("password")); err != nil { - if models.IsErrUserNotExist(err) { + if errors.IsUserNotExist(err) { ctx.RenderWithErr(ctx.Tr("form.enterred_invalid_password"), SETTINGS_DELETE, nil) } else { ctx.Handle(500, "UserSignIn", err) |