summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/private/Files/Cache/Cache.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/private/Files/Cache/Cache.php b/lib/private/Files/Cache/Cache.php
index 5c5146a569f..92e81cd0f07 100644
--- a/lib/private/Files/Cache/Cache.php
+++ b/lib/private/Files/Cache/Cache.php
@@ -797,6 +797,10 @@ class Cache implements ICache {
$query->andWhere($searchExpr);
}
+ if ($searchQuery->limitToHome() && ($this instanceof HomeCache)) {
+ $query->andWhere($builder->expr()->like('path', $query->expr()->literal('files/%')));
+ }
+
$this->querySearchHelper->addSearchOrdersToQuery($query, $searchQuery->getOrder());
if ($searchQuery->getLimit()) {