summaryrefslogtreecommitdiffstats
path: root/lib/private/User/User.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/User/User.php')
-rw-r--r--lib/private/User/User.php5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/private/User/User.php b/lib/private/User/User.php
index dd451c8eb3f..ccf5936c659 100644
--- a/lib/private/User/User.php
+++ b/lib/private/User/User.php
@@ -36,6 +36,7 @@
namespace OC\User;
use OC\Accounts\AccountManager;
+use OC\Avatar\AvatarManager;
use OC\Files\Cache\Storage;
use OC\Hooks\Emitter;
use OC_Helper;
@@ -238,6 +239,10 @@ class User implements IUser {
\OC::$server->getCommentsManager()->deleteReferencesOfActor('users', $this->uid);
\OC::$server->getCommentsManager()->deleteReadMarksFromUser($this);
+ /** @var IAvatarManager $avatarManager */
+ $avatarManager = \OC::$server->query(AvatarManager::class);
+ $avatarManager->deleteUserAvatar($this->uid);
+
$notification = \OC::$server->getNotificationManager()->createNotification();
$notification->setUser($this->uid);
\OC::$server->getNotificationManager()->markProcessed($notification);