diff options
author | Robin Appelman <icewind@owncloud.com> | 2015-03-09 16:20:18 +0100 |
---|---|---|
committer | Robin Appelman <icewind@owncloud.com> | 2015-04-27 14:07:15 +0200 |
commit | 30ad56813a16908e3862c353256f2a6d0f05fe3a (patch) | |
tree | 284153f54d9ad64f377602c2ce6b2dc83f3cc445 /apps/files_sharing/lib/updater.php | |
parent | 518d5aadf51318886481696e4308fcc39684b508 (diff) | |
download | nextcloud-server-30ad56813a16908e3862c353256f2a6d0f05fe3a.tar.gz nextcloud-server-30ad56813a16908e3862c353256f2a6d0f05fe3a.zip |
propagate etags for all user of a share
Diffstat (limited to 'apps/files_sharing/lib/updater.php')
-rw-r--r-- | apps/files_sharing/lib/updater.php | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/apps/files_sharing/lib/updater.php b/apps/files_sharing/lib/updater.php index 322c031f2f1..45cf662d148 100644 --- a/apps/files_sharing/lib/updater.php +++ b/apps/files_sharing/lib/updater.php @@ -50,47 +50,9 @@ class Shared_Updater { } /** - * Correct the parent folders' ETags for all users shared the file at $target - * - * @param string $target - */ - static public function correctFolders($target) { - - // ignore part files - if (pathinfo($target, PATHINFO_EXTENSION) === 'part') { - return false; - } - - // Correct Shared folders of other users shared with - $shares = \OCA\Files_Sharing\Helper::getSharesFromItem($target); - - foreach ($shares as $share) { - if ((int)$share['share_type'] === \OCP\Share::SHARE_TYPE_USER) { - self::correctUsersFolder($share['share_with'], $share['file_target']); - } elseif ((int)$share['share_type'] === \OCP\Share::SHARE_TYPE_GROUP) { - $users = \OC_Group::usersInGroup($share['share_with']); - foreach ($users as $user) { - self::correctUsersFolder($user, $share['file_target']); - } - } else { //unique name for group share - self::correctUsersFolder($share['share_with'], $share['file_target']); - } - } - } - - /** - * @param array $params - */ - static public function writeHook($params) { - self::correctFolders($params['path']); - } - - /** * @param array $params */ static public function renameHook($params) { - self::correctFolders($params['newpath']); - self::correctFolders(pathinfo($params['oldpath'], PATHINFO_DIRNAME)); self::renameChildren($params['oldpath'], $params['newpath']); } @@ -99,7 +61,6 @@ class Shared_Updater { */ static public function deleteHook($params) { $path = $params['path']; - self::correctFolders($path); } /** |