diff options
author | Joas Schilling <coding@schilljs.com> | 2019-02-22 11:47:36 +0300 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2019-03-01 22:56:58 +0300 |
commit | eecd9323c5e79f27051bb56a110ee4f26d630b7a (patch) | |
tree | 6402d0245c527bd69bf7fcdf71f333c4acb5309a | |
parent | 43c8d0c9c28a359e0439e694fa7d1eaf066fc8b3 (diff) |
Also check the access to collections on preparing
Signed-off-by: Joas Schilling <coding@schilljs.com>
-rw-r--r-- | core/Controller/CollaborationResourcesController.php | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/core/Controller/CollaborationResourcesController.php b/core/Controller/CollaborationResourcesController.php index 77f47a9f0a1..4278334c2b9 100644 --- a/core/Controller/CollaborationResourcesController.php +++ b/core/Controller/CollaborationResourcesController.php @@ -225,6 +225,10 @@ class CollaborationResourcesController extends OCSController { } protected function prepareCollection(ICollection $collection): array { + if (!$collection->canAccess($this->userSession->getUser())) { + return null; + } + return [ 'id' => $collection->getId(), 'name' => $collection->getName(), |