Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2017-10-25 11:38:26 +0300
committerJoas Schilling <coding@schilljs.com>2017-10-25 11:38:26 +0300
commit42c84b630946b9cd691e86bf7ad9aadcdc625e98 (patch)
tree011f549b85852ae78c319292c0ab5e0391c9d360 /lib
parentdb1096bcfdf2336ccf6aefb70dd902a63ed615db (diff)
Correctly search for existing collaboration results
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib')
-rw-r--r--lib/private/Collaboration/Collaborators/SearchResult.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/private/Collaboration/Collaborators/SearchResult.php b/lib/private/Collaboration/Collaborators/SearchResult.php
index 7b32b388203..1ab61e257f0 100644
--- a/lib/private/Collaboration/Collaborators/SearchResult.php
+++ b/lib/private/Collaboration/Collaborators/SearchResult.php
@@ -64,8 +64,10 @@ class SearchResult implements ISearchResult {
$resultArrays = [$this->result['exact'][$type], $this->result[$type]];
foreach($resultArrays as $resultArray) {
- if ($resultArray['value']['shareWith'] === $collaboratorId) {
- return true;
+ foreach ($resultArray as $result) {
+ if ($result['value']['shareWith'] === $collaboratorId) {
+ return true;
+ }
}
}