aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaxence Lange <maxence@artificial-owl.com>2025-04-29 15:33:42 -0100
committerAndy Scherzinger <info@andy-scherzinger.de>2025-05-29 01:13:57 +0200
commit9a5e27d5b48c8ff9d6d381f10ed2235af6956e71 (patch)
tree0fd2e19ec4afbed18cce5be055bd85faf65ba033
parent1c2e47231b22452554f2d17fa8fde48d66080b79 (diff)
downloadnextcloud-server-backport/52543/stable30.tar.gz
nextcloud-server-backport/52543/stable30.zip
fix(share): assume download enabled on federated sharebackport/52543/stable30
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
-rw-r--r--apps/files_sharing/lib/Controller/ShareAPIController.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/apps/files_sharing/lib/Controller/ShareAPIController.php b/apps/files_sharing/lib/Controller/ShareAPIController.php
index d71e4fff401..d11834e1e07 100644
--- a/apps/files_sharing/lib/Controller/ShareAPIController.php
+++ b/apps/files_sharing/lib/Controller/ShareAPIController.php
@@ -2089,6 +2089,8 @@ class ShareAPIController extends OCSController {
$hideDownload = $hideDownload && $originalShare->getHideDownload();
// allow download if already allowed by previous share or when the current share allows downloading
$canDownload = $canDownload || $inheritedAttributes === null || $inheritedAttributes->getAttribute('permissions', 'download') !== false;
+ } elseif ($node->getStorage()->instanceOfStorage(Storage::class)) {
+ $canDownload = true; // in case of federation storage, we can expect the download to be activated by default
}
}