aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/Files/Node
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/Files/Node
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/Files/Node')
-rw-r--r--lib/private/Files/Node/Folder.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/private/Files/Node/Folder.php b/lib/private/Files/Node/Folder.php
index 668893f6549..134455dd945 100644
--- a/lib/private/Files/Node/Folder.php
+++ b/lib/private/Files/Node/Folder.php
@@ -528,7 +528,11 @@ class Folder extends Node implements \OCP\Files\Folder {
->setMaxResults($limit)
->setFirstResult($offset);
- return $query->execute()->fetchAll();
+ $result = $query->execute();
+ $rows = $result->fetchAll();
+ $result->closeCursor();
+
+ return $rows;
}
private function recentParse($result, $mountMap, $mimetypeLoader) {