mirror of
https://github.com/nextcloud/server.git
synced 2026-06-12 10:10:49 -04:00
fix uncaught exception on not permitted file types when setting avatar, fixes #17232
This commit is contained in:
parent
85b7bde7d4
commit
b37d62d9d3
1 changed files with 7 additions and 1 deletions
|
|
@ -342,7 +342,13 @@ class User {
|
|||
}
|
||||
|
||||
$avatar = $this->avatarManager->getAvatar($this->uid);
|
||||
$avatar->set($this->image);
|
||||
try {
|
||||
$avatar->set($this->image);
|
||||
} catch (\Exception $e) {
|
||||
\OC::$server->getLogger()->notice(
|
||||
'Could not set avatar for ' . $this->dn . ', because: ' . $e->getMessage(),
|
||||
['app' => 'user_ldap']);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue