summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@owncloud.com>2016-03-21 14:13:38 +0100
committerRoeland Jago Douma <rullzer@owncloud.com>2016-03-22 11:13:11 +0100
commitdcca20a48a18cf9349084851ab4bbc05046808b3 (patch)
tree434cb7c507458b41168c5c00c12e522fd22be144 /lib
parent9fc371e436e8f99c862e587efe1b682cb0923e83 (diff)
downloadnextcloud-server-dcca20a48a18cf9349084851ab4bbc05046808b3.tar.gz
nextcloud-server-dcca20a48a18cf9349084851ab4bbc05046808b3.zip
Save the query when we get tags for no objects
Diffstat (limited to 'lib')
-rw-r--r--lib/private/systemtag/systemtagobjectmapper.php2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/private/systemtag/systemtagobjectmapper.php b/lib/private/systemtag/systemtagobjectmapper.php
index 586351cf8c1..412842b69e3 100644
--- a/lib/private/systemtag/systemtagobjectmapper.php
+++ b/lib/private/systemtag/systemtagobjectmapper.php
@@ -64,6 +64,8 @@ class SystemTagObjectMapper implements ISystemTagObjectMapper {
public function getTagIdsForObjects($objIds, $objectType) {
if (!is_array($objIds)) {
$objIds = [$objIds];
+ } else if (empty($objIds)) {
+ return [];
}
$query = $this->connection->getQueryBuilder();