summaryrefslogtreecommitdiffstats
path: root/utils/password.go
diff options
context:
space:
mode:
Diffstat (limited to 'utils/password.go')
-rw-r--r--utils/password.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/utils/password.go b/utils/password.go
index dc1d771b8..b129869d3 100644
--- a/utils/password.go
+++ b/utils/password.go
@@ -4,8 +4,10 @@
package utils
import (
- "github.com/mattermost/platform/model"
+ "net/http"
"strings"
+
+ "github.com/mattermost/platform/model"
)
func IsPasswordValid(password string) *model.AppError {
@@ -57,7 +59,7 @@ func IsPasswordValid(password string) *model.AppError {
}
if isError {
- return model.NewLocAppError("User.IsValid", id+".app_error", map[string]interface{}{"Min": min}, "")
+ return model.NewAppError("User.IsValid", id+".app_error", map[string]interface{}{"Min": min}, "", http.StatusBadRequest)
}
return nil