From 698b9e2acc4daafe7d2b314e2d8c96545dde9c40 Mon Sep 17 00:00:00 2001 From: Unknwon Date: Thu, 26 Mar 2015 17:11:47 -0400 Subject: #1070 Clearer error message for illegal characters --- routers/install.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'routers/install.go') diff --git a/routers/install.go b/routers/install.go index f5dc0c580b..6da611286f 100644 --- a/routers/install.go +++ b/routers/install.go @@ -239,7 +239,7 @@ func InstallPost(ctx *middleware.Context, form auth.InstallForm) { // Create admin account. if err := models.CreateUser(&models.User{Name: form.AdminName, Email: form.AdminEmail, Passwd: form.AdminPasswd, IsAdmin: true, IsActive: true}); err != nil { - if err != models.ErrUserAlreadyExist { + if !models.IsErrUserAlreadyExist(err) { setting.InstallLock = false ctx.Data["Err_AdminName"] = true ctx.Data["Err_AdminEmail"] = true -- cgit v1.2.3