Skip to content
Snippets Groups Projects
Commit 1ccc99ed authored by Daniel Calviño Sánchez's avatar Daniel Calviño Sánchez
Browse files

Add support for room shares to the share owner updater


A user can move her own shares into a received share. When that happens
she is effectively handing over the ownership of the file, so the share
needs to be updated to reflect the new owner.

Signed-off-by: default avatarDaniel Calviño Sánchez <danxuliu@gmail.com>
parent 8084ba51
No related branches found
No related tags found
No related merge requests found
...@@ -59,6 +59,7 @@ class Updater { ...@@ -59,6 +59,7 @@ class Updater {
$shares = $shareManager->getSharesBy($userFolder->getOwner()->getUID(), \OCP\Share::SHARE_TYPE_USER, $src, false, -1); $shares = $shareManager->getSharesBy($userFolder->getOwner()->getUID(), \OCP\Share::SHARE_TYPE_USER, $src, false, -1);
$shares = array_merge($shares, $shareManager->getSharesBy($userFolder->getOwner()->getUID(), \OCP\Share::SHARE_TYPE_GROUP, $src, false, -1)); $shares = array_merge($shares, $shareManager->getSharesBy($userFolder->getOwner()->getUID(), \OCP\Share::SHARE_TYPE_GROUP, $src, false, -1));
$shares = array_merge($shares, $shareManager->getSharesBy($userFolder->getOwner()->getUID(), \OCP\Share::SHARE_TYPE_ROOM, $src, false, -1));
// If the path we move is not a share we don't care // If the path we move is not a share we don't care
if (empty($shares)) { if (empty($shares)) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment