Skip to content

Commit

Permalink
Merge pull request #789 from nextcloud/fix/null-user
Browse files Browse the repository at this point in the history
  • Loading branch information
skjnldsv authored Feb 6, 2024
2 parents 14d78b4 + 5647aa5 commit bd218e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/Controller/LoginController.php
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ public function code(string $state = '', string $code = '', string $scope = '',
$this->ldapService->syncUser($userId);
// when auto provision is disabled, we assume the user has been created by another user backend (or manually)
$user = $this->userManager->get($userId);
if ($this->ldapService->isLdapDeletedUser($user)) {
if ($user !== null && $this->ldapService->isLdapDeletedUser($user)) {
$user = null;
}
}
Expand Down

0 comments on commit bd218e9

Please sign in to comment.