aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/TagManager.php
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2020-11-05 10:50:53 +0100
committerJoas Schilling <coding@schilljs.com>2020-11-09 12:28:17 +0100
commit8027dcbc6f6b1653f5ebcf04b1862ac1e1f51d32 (patch)
tree1bf182f477bfbead7b75ae14a8cd0fce5bb38ada /lib/private/TagManager.php
parent72545ffd07a07f142c9c18b3e4afc9ae1b5c8da2 (diff)
downloadnextcloud-server-8027dcbc6f6b1653f5ebcf04b1862ac1e1f51d32.tar.gz
nextcloud-server-8027dcbc6f6b1653f5ebcf04b1862ac1e1f51d32.zip
Don't leave cursors open when tests fail
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/private/TagManager.php')
-rw-r--r--lib/private/TagManager.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/private/TagManager.php b/lib/private/TagManager.php
index 4613b6247f4..155efccfaa7 100644
--- a/lib/private/TagManager.php
+++ b/lib/private/TagManager.php
@@ -102,6 +102,10 @@ class TagManager implements ITagManager {
->andWhere($query->expr()->eq('c.type', $query->createNamedParameter($objectType)))
->andWhere($query->expr()->eq('c.category', $query->createNamedParameter(ITags::TAG_FAVORITE)));
- return $query->execute()->fetchAll(\PDO::FETCH_COLUMN);
+ $result = $query->execute();
+ $users = $result->fetchAll(\PDO::FETCH_COLUMN);
+ $result->closeCursor();
+
+ return $users;
}
}