only unshare user share if it was shared with the current user

remotes/origin/ldap_group_count
Bjoern Schiessle 12 years ago committed by Robin Appelman
parent 5bbfdc35d7
commit eec1c4398a
  1. 3
      lib/private/share/share.php

@ -731,7 +731,8 @@ class Share extends \OC\Share\Constants {
$itemUnshared = false;
foreach ($shares as $share) {
if ((int)$share['share_type'] === \OCP\Share::SHARE_TYPE_USER) {
if ((int)$share['share_type'] === \OCP\Share::SHARE_TYPE_USER &&
$share['share_with'] === \OCP\User::getUser()) {
Helper::delete($share['id']);
$itemUnshared = true;
break;

Loading…
Cancel
Save