aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorskjnldsv <skjnldsv@protonmail.com>2024-07-31 17:29:46 +0200
committerJohn Molakvoæ <skjnldsv@users.noreply.github.com>2024-08-05 20:36:45 +0200
commit712965daa111eacbd9bd8af893a1828369f3ecc4 (patch)
tree2cbcfece3432f726f7ebbf434eb24a25bca75629 /apps
parent9ef2e142c4614596f95772d9145b158ecab68e58 (diff)
downloadnextcloud-server-712965daa111eacbd9bd8af893a1828369f3ecc4.tar.gz
nextcloud-server-712965daa111eacbd9bd8af893a1828369f3ecc4.zip
fix(files_sharing): filter out invalid shareWith in sharee API
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
Diffstat (limited to 'apps')
-rw-r--r--apps/files_sharing/lib/Controller/ShareesAPIController.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/files_sharing/lib/Controller/ShareesAPIController.php b/apps/files_sharing/lib/Controller/ShareesAPIController.php
index ec4192e94c1..13a420728ef 100644
--- a/apps/files_sharing/lib/Controller/ShareesAPIController.php
+++ b/apps/files_sharing/lib/Controller/ShareesAPIController.php
@@ -257,7 +257,7 @@ class ShareesAPIController extends OCSController {
$sharees = $this->getAllShareesByType($user, $shareType);
$shareTypeResults = [];
foreach ($sharees as [$sharee, $displayname]) {
- if (!isset($this->searchResultTypeMap[$shareType])) {
+ if (!isset($this->searchResultTypeMap[$shareType]) || trim($sharee) === '') {
continue;
}