mirror of
https://github.com/casdoor/casdoor.git
synced 2025-07-03 04:10:20 +08:00
refactor: code-optimization (#1885)
* refactor: code-optimization * fix: restoring code style * fix: gofmt
This commit is contained in:
@ -248,7 +248,7 @@ func CheckUserPassword(organization string, username string, password string, la
|
||||
enableCaptcha = options[0]
|
||||
}
|
||||
user := GetUserByFields(organization, username)
|
||||
if user == nil || user.IsDeleted == true {
|
||||
if user == nil || user.IsDeleted {
|
||||
return nil, fmt.Sprintf(i18n.Translate(lang, "general:The user: %s doesn't exist"), util.GetId(organization, username))
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user