aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMaxence Lange <maxence@artificial-owl.com>2025-07-11 23:02:03 +0200
committerMaxence Lange <maxence@artificial-owl.com>2025-07-11 23:02:03 +0200
commit416625dc9e76cbeb4de0a3a95bcfbeff64e6f41a (patch)
tree610f707ea5d0d7b24bd54517647cf3da301feb77
parent9a8e74dc73b7f29476edce28ecf40ab5c8603542 (diff)
downloadnextcloud-server-fix/noid/fed-share-on-local-reshare.tar.gz
nextcloud-server-fix/noid/fed-share-on-local-reshare.zip
feat(federated-share): forward notification only on remote resharefix/noid/fed-share-on-local-reshare
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
-rw-r--r--apps/federatedfilesharing/lib/OCM/CloudFederationProviderFiles.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/apps/federatedfilesharing/lib/OCM/CloudFederationProviderFiles.php b/apps/federatedfilesharing/lib/OCM/CloudFederationProviderFiles.php
index 1cdcdbdd6d4..1ce639532e8 100644
--- a/apps/federatedfilesharing/lib/OCM/CloudFederationProviderFiles.php
+++ b/apps/federatedfilesharing/lib/OCM/CloudFederationProviderFiles.php
@@ -309,7 +309,10 @@ class CloudFederationProviderFiles implements ISignedCloudFederationProvider {
$this->verifyShare($share, $token);
$this->executeAcceptShare($share);
- if ($share->getShareOwner() !== $share->getSharedBy()) {
+
+ if ($share->getShareOwner() !== $share->getSharedBy()
+ && !$this->userManager->userExists($share->getSharedBy())) {
+ // only if share was initiated from another instance
[, $remote] = $this->addressHandler->splitUserRemote($share->getSharedBy());
$remoteId = $this->federatedShareProvider->getRemoteId($share);
$notification = $this->cloudFederationFactory->getCloudFederationNotification();