Skip to content

Commit

Permalink
Don't return system calendars if requesting shares for resources.
Browse files Browse the repository at this point in the history
  • Loading branch information
yunosh committed Mar 7, 2016
1 parent 172de06 commit 03e553d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion kronolith/lib/Shares.php
Expand Up @@ -76,7 +76,8 @@ public function listShares($userid, array $params = array())

// Must explicitly include system shares if the user is an admin since
// there may be some shares that do not have perms set.
if ($GLOBALS['registry']->isAdmin()) {
if ($attributes['calendar_type'] == Kronolith::SHARE_TYPE_USER &&
$GLOBALS['registry']->isAdmin()) {
$shares = array_merge($shares, $this->listSystemShares());
}

Expand Down

0 comments on commit 03e553d

Please sign in to comment.