summaryrefslogtreecommitdiffstats
path: root/lib/private/Share20/DefaultShareProvider.php
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2017-04-11 12:40:36 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2017-04-13 12:58:52 +0200
commit629b7c0fc38d9a2c33805bfcf4359e263e4ae68f (patch)
tree915d48dcfbc021fad3cbff2a5c53e7de006e630e /lib/private/Share20/DefaultShareProvider.php
parent6c23a5fa3511e5212c83e8407fa18b12ec975f97 (diff)
downloadnextcloud-server-629b7c0fc38d9a2c33805bfcf4359e263e4ae68f.tar.gz
nextcloud-server-629b7c0fc38d9a2c33805bfcf4359e263e4ae68f.zip
Adjust docs and make !$currentAccess simpler
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/private/Share20/DefaultShareProvider.php')
-rw-r--r--lib/private/Share20/DefaultShareProvider.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/private/Share20/DefaultShareProvider.php b/lib/private/Share20/DefaultShareProvider.php
index b28dc56f852..ed3651df9b2 100644
--- a/lib/private/Share20/DefaultShareProvider.php
+++ b/lib/private/Share20/DefaultShareProvider.php
@@ -1136,9 +1136,11 @@ class DefaultShareProvider implements IShareProvider {
}
$cursor->closeCursor();
- $users = array_map([$this, 'filterSharesOfUser'], $users);
if ($currentAccess === true) {
+ $users = array_map([$this, 'filterSharesOfUser'], $users);
$users = array_filter($users);
+ } else {
+ $users = array_keys($users);
}
return ['users' => $users, 'public' => $link];