summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSam Tuke <samtuke@owncloud.com>2013-01-14 17:06:48 +0000
committerSam Tuke <samtuke@owncloud.com>2013-01-14 17:06:48 +0000
commit23db814cbd09e89824f6fee4fcef9e64a54c0458 (patch)
treec2a46a0c40ea6868403f9116326f14a2321fe05e
parent1641ed8ac7284f71b974b49336957cb5b6d1798c (diff)
parentde0ed634f2fb1bb9fbb93f6c0a66882dea42e288 (diff)
downloadnextcloud-server-23db814cbd09e89824f6fee4fcef9e64a54c0458.tar.gz
nextcloud-server-23db814cbd09e89824f6fee4fcef9e64a54c0458.zip
Merge branch 'master' into files_encryption
-rw-r--r--lib/public/share.php13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/public/share.php b/lib/public/share.php
index 8c0cfc16b4e..0ff68fe265a 100644
--- a/lib/public/share.php
+++ b/lib/public/share.php
@@ -465,6 +465,13 @@ class Share {
null,
1);
if ($item) {
+ // Pass all the vars we have for now, they may be useful
+ \OC_Hook::emit('OCP\Share', 'pre_unshare', array(
+ 'itemType' => $itemType,
+ 'itemSource' => $itemSource,
+ 'shareType' => $shareType,
+ 'shareWith' => $shareWith,
+ ));
self::delete($item['id']);
return true;
}
@@ -480,6 +487,12 @@ class Share {
public static function unshareAll($itemType, $itemSource) {
$shares = self::getItemShared($itemType, $itemSource);
if ($shares) {
+ // Pass all the vars we have for now, they may be useful
+ \OC_Hook::emit('OCP\Share', 'pre_unshareAll', array(
+ 'itemType' => $itemType,
+ 'itemSource' => $itemSource,
+ 'shares' => $shares
+ ));
foreach ($shares as $share) {
self::delete($share['id']);
}