[v9.4.x] LDAP: Fix user disabling (#74318)
* [LDAP] Disable removed users on login (#74016) * manual backport of #74016 on legacy code * LDAP: Fix active sync with large quantities of users (#73834) * Fix authenticate user test
This commit is contained in:
@@ -17,6 +17,7 @@ type FakeUserService struct {
|
||||
|
||||
GetSignedInUserFn func(ctx context.Context, query *user.GetSignedInUserQuery) (*user.SignedInUser, error)
|
||||
CreateFn func(ctx context.Context, cmd *user.CreateUserCommand) (*user.User, error)
|
||||
DisableFn func(ctx context.Context, cmd *user.DisableUserCommand) error
|
||||
|
||||
counter int
|
||||
}
|
||||
@@ -92,6 +93,10 @@ func (f *FakeUserService) Search(ctx context.Context, query *user.SearchUsersQue
|
||||
}
|
||||
|
||||
func (f *FakeUserService) Disable(ctx context.Context, cmd *user.DisableUserCommand) error {
|
||||
if f.DisableFn != nil {
|
||||
return f.DisableFn(ctx, cmd)
|
||||
}
|
||||
|
||||
return f.ExpectedError
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user