diff options
author | Julius Härtl <jus@bitgrid.net> | 2021-03-03 14:26:35 +0100 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2021-03-03 14:26:35 +0100 |
commit | 930b40bd8af4b646d8e6f7950a903dc11e6a8d32 (patch) | |
tree | 67c08ecb33521718c7a99ccdab0b24cdeb4f568e /apps/files_trashbin/lib | |
parent | a1be5f33af7e65a80b2e39d7c28c727c6f3ef6fe (diff) | |
download | nextcloud-server-930b40bd8af4b646d8e6f7950a903dc11e6a8d32.tar.gz nextcloud-server-930b40bd8af4b646d8e6f7950a903dc11e6a8d32.zip |
Remove trash items from other trash backends when deleting all
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'apps/files_trashbin/lib')
-rw-r--r-- | apps/files_trashbin/lib/Sabre/TrashRoot.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/files_trashbin/lib/Sabre/TrashRoot.php b/apps/files_trashbin/lib/Sabre/TrashRoot.php index c2e96b20d32..5d41a81e670 100644 --- a/apps/files_trashbin/lib/Sabre/TrashRoot.php +++ b/apps/files_trashbin/lib/Sabre/TrashRoot.php @@ -50,6 +50,9 @@ class TrashRoot implements ICollection { public function delete() { \OCA\Files_Trashbin\Trashbin::deleteAll(); + foreach ($this->trashManager->listTrashRoot($this->user) as $trashItem) { + $this->trashManager->removeItem($trashItem); + } } public function getName(): string { |