Skip to content

Commit 704a993

Browse files
butonicDeepDiver1975
authored andcommitted
Fix null pointer exception in user_ldap (#25062)
1 parent 755c86e commit 704a993

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

apps/user_ldap/lib/Access.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -732,7 +732,14 @@ public function batchApplyUserAttributes(array $ldapRecords){
732732
$user->unmark();
733733
$user = $this->userManager->get($ocName);
734734
}
735-
$user->processAttributes($userRecord);
735+
if ($user !== null) {
736+
$user->processAttributes($userRecord);
737+
} else {
738+
\OC::$server->getLogger()->debug(
739+
"The ldap user manager returned null for $ocName",
740+
['app'=>'user_ldap']
741+
);
742+
}
736743
}
737744
}
738745

0 commit comments

Comments
 (0)