Skip to content

Commit db3093a

Browse files
icewind1991PVince81
authored andcommitted
delete files before cleaning cache when cleaning user files
otherwise, when using object store, we loose track of which files the user owns before we can delete them Signed-off-by: Robin Appelman <[email protected]>
1 parent 12e3e85 commit db3093a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/private/Authentication/Listeners/UserDeletedFilesCleanupListener.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,12 +72,12 @@ public function handle(Event $event): void {
7272
}
7373
$storage = $this->homeStorageCache[$event->getUser()->getUID()];
7474
$cache = $storage->getCache();
75+
$storage->rmdir('');
7576
if ($cache instanceof Cache) {
7677
$cache->clear();
7778
} else {
7879
throw new \Exception("Home storage has invalid cache");
7980
}
80-
$storage->rmdir('');
8181
}
8282
}
8383
}

0 commit comments

Comments
 (0)