]> source.dussan.org Git - nextcloud-server.git/commitdiff
use deletion time instead of mtime in trashbin handling 42558/head
authorRobin Appelman <robin@icewind.nl>
Wed, 3 Jan 2024 13:41:58 +0000 (14:41 +0100)
committerRobin Appelman <robin@icewind.nl>
Wed, 3 Jan 2024 13:41:58 +0000 (14:41 +0100)
Signed-off-by: Robin Appelman <robin@icewind.nl>
apps/files_trashbin/lib/Sabre/TrashFile.php
apps/files_trashbin/lib/Sabre/TrashFolder.php

index d9dc102ac831c23d19f97803bd514473ea9e5f19..a33514794876369445affab0b02cc794d479969f 100644 (file)
@@ -30,10 +30,10 @@ use OCA\Files_Trashbin\Trashbin;
 
 class TrashFile extends AbstractTrashFile {
        public function get() {
-               return $this->data->getStorage()->fopen(Trashbin::getTrashFilename($this->data->getInternalPath(), $this->getLastModified()), 'rb');
+               return $this->data->getStorage()->fopen(Trashbin::getTrashFilename($this->data->getInternalPath(), $this->getDeletionTime()), 'rb');
        }
 
        public function getName(): string {
-               return Trashbin::getTrashFilename($this->data->getName(), $this->getLastModified());
+               return Trashbin::getTrashFilename($this->data->getName(), $this->getDeletionTime());
        }
 }
index 4623913b18a78d7965ac809d86632d45a17cfb1f..fed39d67aa0c1b47baf62970b3b30bfb01254187 100644 (file)
@@ -30,6 +30,6 @@ use OCA\Files_Trashbin\Trashbin;
 
 class TrashFolder extends AbstractTrashFolder {
        public function getName(): string {
-               return Trashbin::getTrashFilename($this->data->getName(), $this->getLastModified());
+               return Trashbin::getTrashFilename($this->data->getName(), $this->getDeletionTime());
        }
 }