mirror of
https://github.com/nextcloud/server.git
synced 2026-06-09 00:32:29 -04:00
chore(user_ldap): Rename avatar setting method to a more suited name
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
This commit is contained in:
parent
9c717aa701
commit
c0cb8ec7d4
1 changed files with 2 additions and 7 deletions
|
|
@ -691,7 +691,7 @@ class User {
|
|||
return true;
|
||||
}
|
||||
|
||||
$isSet = $this->setOwnCloudAvatar();
|
||||
$isSet = $this->setNextcloudAvatar();
|
||||
|
||||
if ($isSet) {
|
||||
// save checksum only after successful setting
|
||||
|
|
@ -712,9 +712,8 @@ class User {
|
|||
|
||||
/**
|
||||
* @brief sets an image as Nextcloud avatar
|
||||
* @return bool
|
||||
*/
|
||||
private function setOwnCloudAvatar() {
|
||||
private function setNextcloudAvatar(): bool {
|
||||
if (!$this->image->valid()) {
|
||||
$this->logger->error('avatar image data from LDAP invalid for ' . $this->dn, ['app' => 'user_ldap']);
|
||||
return false;
|
||||
|
|
@ -728,10 +727,6 @@ class User {
|
|||
return false;
|
||||
}
|
||||
|
||||
if (!$this->fs->isLoaded()) {
|
||||
$this->fs->setup($this->uid);
|
||||
}
|
||||
|
||||
try {
|
||||
$avatar = $this->avatarManager->getAvatar($this->uid);
|
||||
$avatar->set($this->image);
|
||||
|
|
|
|||
Loading…
Reference in a new issue