mirror of
https://github.com/grafana/grafana.git
synced 2024-11-23 09:26:43 -06:00
cleanup, make sure users are always synced with ldap
This commit is contained in:
parent
33760b5c3b
commit
3fedcb1e4b
@ -68,12 +68,7 @@ func UpsertUser(cmd *m.UpsertUserCommand) error {
|
||||
}
|
||||
}
|
||||
|
||||
err = syncOrgRoles(cmd.Result, extUser)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
return syncOrgRoles(cmd.Result, extUser)
|
||||
}
|
||||
|
||||
func createUser(extUser *m.ExternalUserInfo) (*m.User, error) {
|
||||
|
@ -65,6 +65,8 @@ func initContextWithAuthProxy(ctx *m.ReqContext, orgID int64) bool {
|
||||
query.UserId = getRequestUserId(ctx)
|
||||
// if we're using ldap, pass authproxy login name to ldap user sync
|
||||
} else if setting.LdapEnabled {
|
||||
ctx.Session.Delete(session.SESS_KEY_LASTLDAPSYNC)
|
||||
|
||||
syncQuery := &m.LoginUserQuery{
|
||||
ReqContext: ctx,
|
||||
Username: proxyHeaderValue,
|
||||
|
Loading…
Reference in New Issue
Block a user