summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorVincent Petry <vincent@nextcloud.com>2022-07-26 23:08:04 +0200
committerGitHub <noreply@github.com>2022-07-26 23:08:04 +0200
commitcb9f3423e246708821bd7cee5a9e530d9a5bbcbb (patch)
tree1e109cbbf2481be58b8f1666cefea3b4664ba4fe /lib
parentac4e60e6f43125dc2adc2545ba426d74a62b9ed0 (diff)
parentdb3093a46f8719276eefd4d0d117d8da7670e8e5 (diff)
downloadnextcloud-server-cb9f3423e246708821bd7cee5a9e530d9a5bbcbb.tar.gz
nextcloud-server-cb9f3423e246708821bd7cee5a9e530d9a5bbcbb.zip
Merge pull request #30510 from nextcloud/user-cleanup-storage-before-cache
delete files before cleaning cache when cleaning user files
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Authentication/Listeners/UserDeletedFilesCleanupListener.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Authentication/Listeners/UserDeletedFilesCleanupListener.php b/lib/private/Authentication/Listeners/UserDeletedFilesCleanupListener.php
index 2fb05159d09..5e657be0763 100644
--- a/lib/private/Authentication/Listeners/UserDeletedFilesCleanupListener.php
+++ b/lib/private/Authentication/Listeners/UserDeletedFilesCleanupListener.php
@@ -72,12 +72,12 @@ class UserDeletedFilesCleanupListener implements IEventListener {
}
$storage = $this->homeStorageCache[$event->getUser()->getUID()];
$cache = $storage->getCache();
+ $storage->rmdir('');
if ($cache instanceof Cache) {
$cache->clear();
} else {
throw new \Exception("Home storage has invalid cache");
}
- $storage->rmdir('');
}
}
}