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 f55807bc769..5e5d3f0d772 100644
--- a/lib/private/User/User.php
+++ b/lib/private/User/User.php
@@ -30,6 +30,7 @@
namespace OC\User;
+use OC\Accounts\AccountManager;
use OC\Files\Cache\Storage;
use OC\Hooks\Emitter;
use OC_Helper;
@@ -235,6 +236,10 @@ class User implements IUser {
$notification->setUser($this->uid);
\OC::$server->getNotificationManager()->markProcessed($notification);
+ /** @var AccountManager $accountManager */
+ $accountManager = \OC::$server->query(AccountManager::class);
+ $accountManager->deleteUser($this);
+
if ($this->emitter) {
$this->emitter->emit('\OC\User', 'postDelete', array($this));
}