From 6f6b7e4e97f466ee0f29c96b7fee0d9b98ce751c Mon Sep 17 00:00:00 2001 From: George Goldberg Date: Fri, 28 Apr 2017 23:01:56 +0100 Subject: Add Password field to Bulk Importer. (#6268) --- model/user.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'model/user.go') diff --git a/model/user.go b/model/user.go index f983139f9..48d85526d 100644 --- a/model/user.go +++ b/model/user.go @@ -36,6 +36,7 @@ const ( USER_AUTH_DATA_MAX_LENGTH = 128 USER_NAME_MAX_LENGTH = 64 USER_NAME_MIN_LENGTH = 1 + USER_PASSWORD_MAX_LENGTH = 72 ) type User struct { @@ -130,7 +131,7 @@ func (u *User) IsValid() *AppError { return InvalidUserError("auth_data_pwd", u.Id) } - if len(u.Password) > 72 { + if len(u.Password) > USER_PASSWORD_MAX_LENGTH { return InvalidUserError("password_limit", u.Id) } -- cgit v1.2.3-1-g7c22