diff options
author | Unknwon <u@gogs.io> | 2015-09-14 11:03:42 -0400 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2015-09-14 11:03:42 -0400 |
commit | d600530c201339818ccf329ddce21bfeff82f798 (patch) | |
tree | fb0391c437e2dc13d4b4c71a87cc3b8c44db13aa /models | |
parent | 2d1bb0cf49766e1acf5d3da824dee514ada6ff9d (diff) | |
download | gitea-d600530c201339818ccf329ddce21bfeff82f798.tar.gz gitea-d600530c201339818ccf329ddce21bfeff82f798.zip |
#1635 PAM return error bug
Diffstat (limited to 'models')
-rw-r--r-- | models/login.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/models/login.go b/models/login.go index 3920fbf107..1b7ecdf417 100644 --- a/models/login.go +++ b/models/login.go @@ -388,7 +388,7 @@ func LoginUserSMTPSource(u *User, name, passwd string, sourceId int64, cfg *SMTP func LoginUserPAMSource(u *User, name, passwd string, sourceId int64, cfg *PAMConfig, autoRegister bool) (*User, error) { if err := pam.PAMAuth(cfg.ServiceName, name, passwd); err != nil { if strings.Contains(err.Error(), "Authentication failure") { - return nil, ErrUserNotExist{u.Id, u.Name} + return nil, ErrUserNotExist{0, name} } return nil, err } |