summaryrefslogtreecommitdiffstats
path: root/lib/private/Collaboration
diff options
context:
space:
mode:
Diffstat (limited to 'lib/private/Collaboration')
-rw-r--r--lib/private/Collaboration/Collaborators/UserPlugin.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Collaboration/Collaborators/UserPlugin.php b/lib/private/Collaboration/Collaborators/UserPlugin.php
index 946baf687c5..123fa731445 100644
--- a/lib/private/Collaboration/Collaborators/UserPlugin.php
+++ b/lib/private/Collaboration/Collaborators/UserPlugin.php
@@ -153,7 +153,7 @@ class UserPlugin implements ISearchPlugin {
if ($this->shareWithGroupOnly) {
// Only add, if we have a common group
- $commonGroups = array_intersect($userGroupIds, $this->groupManager->getUserGroupIds($user));
+ $commonGroups = array_intersect($currentUserGroups, $this->groupManager->getUserGroupIds($user));
$addUser = !empty($commonGroups);
}