Browse Source

Merge pull request #17387 from nextcloud/fix/remove/federated_share

Allow removing federated shares of locally reshared files
tags/v18.0.0beta1
Roeland Jago Douma 4 years ago
parent
commit
637c50e647
No account linked to committer's email address
1 changed files with 5 additions and 0 deletions
  1. 5
    0
      apps/federatedfilesharing/lib/FederatedShareProvider.php

+ 5
- 0
apps/federatedfilesharing/lib/FederatedShareProvider.php View File

@@ -563,6 +563,11 @@ class FederatedShareProvider implements IShareProvider {
* @throws \OC\HintException
*/
protected function revokeShare($share, $isOwner) {
if ($this->userManager->userExists($share->getShareOwner() && $this->userManager->userExists($share->getSharedBy()))) {
// If both the owner and the initiator of the share are local users we don't have to notify anybody else
return;
}

// also send a unShare request to the initiator, if this is a different user than the owner
if ($share->getShareOwner() !== $share->getSharedBy()) {
if ($isOwner) {

Loading…
Cancel
Save