mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2024-12-24 12:29:05 +01:00
Retry fetching user after CanLogin
This commit is contained in:
parent
65cf86586a
commit
80aed87415
@ -211,6 +211,10 @@ func (auth *Authentication) Login(
|
||||
if !authenticator.CanLogin(dbUser, username, rw, r) {
|
||||
continue
|
||||
}
|
||||
dbUser, err = auth.GetUser(username)
|
||||
if err != nil && err != sql.ErrNoRows {
|
||||
log.Errorf("Error while loading user '%v'", username)
|
||||
}
|
||||
|
||||
user, err := authenticator.Login(dbUser, rw, r)
|
||||
if err != nil {
|
||||
|
Loading…
Reference in New Issue
Block a user