|
|
|
|
@ -326,6 +326,20 @@ class Share { |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* @brief Unshare an item from all users, groups, and remove all links |
|
|
|
|
* @param string Item type |
|
|
|
|
* @param string Item source |
|
|
|
|
* @return Returns true on success or false on failure |
|
|
|
|
*/ |
|
|
|
|
public static function unshareAll($itemType, $itemSource) { |
|
|
|
|
if ($item = self::getItemShared($itemType, $itemSource)) { |
|
|
|
|
self::delete($item['id']); |
|
|
|
|
return true; |
|
|
|
|
} |
|
|
|
|
return false; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* @brief Unshare an item shared with the current user |
|
|
|
|
* @param string Item type |
|
|
|
|
|