aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorLouis Chemineau <louis@chmn.me>2024-11-19 13:04:47 +0100
committerLouis Chemineau <louis@chmn.me>2024-12-05 10:35:42 +0100
commit9ff3ba7ce02cfb76bd1cdb1df97ac7d7e4fda0a6 (patch)
tree5f0b5b5afd3e21d9110fd6bb907426744151fe3b /apps
parentbe7b6a7b1b54e6ff967cf54dd305eeb15782490a (diff)
downloadnextcloud-server-9ff3ba7ce02cfb76bd1cdb1df97ac7d7e4fda0a6.tar.gz
nextcloud-server-9ff3ba7ce02cfb76bd1cdb1df97ac7d7e4fda0a6.zip
fix: Correctly create NonExistingFolder during copy
Signed-off-by: Louis Chemineau <louis@chmn.me>
Diffstat (limited to 'apps')
-rw-r--r--apps/files_versions/lib/Listener/VersionStorageMoveListener.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/files_versions/lib/Listener/VersionStorageMoveListener.php b/apps/files_versions/lib/Listener/VersionStorageMoveListener.php
index b4b00108e43..8bf1d4dce7b 100644
--- a/apps/files_versions/lib/Listener/VersionStorageMoveListener.php
+++ b/apps/files_versions/lib/Listener/VersionStorageMoveListener.php
@@ -11,6 +11,7 @@ namespace OCA\Files_Versions\Listener;
use Exception;
use OC\Files\Node\NonExistingFile;
+use OC\Files\Node\NonExistingFolder;
use OCA\Files_Versions\Versions\IVersionBackend;
use OCA\Files_Versions\Versions\IVersionManager;
use OCA\Files_Versions\Versions\IVersionsImporterBackend;
@@ -130,7 +131,7 @@ class VersionStorageMoveListener implements IEventListener {
}
private function getNodeStorage(Node $node): IStorage {
- if ($node instanceof NonExistingFile) {
+ if ($node instanceof NonExistingFile || $node instanceof NonExistingFolder) {
return $node->getParent()->getStorage();
} else {
return $node->getStorage();