We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent edb3b0d commit 736898eCopy full SHA for 736898e
1 file changed
lib/private/Comments/Manager.php
@@ -654,16 +654,16 @@ public function getNumberOfUnreadCommentsForObjects(string $objectType, array $o
654
$query->andWhere($query->expr()->eq('c.verb', $query->createNamedParameter($verb)));
655
}
656
657
+ $unreadComments = array_fill_keys($objectIds, 0);
658
foreach (array_chunk($objectIds, 1000) as $chunk) {
659
$query->setParameter('ids', $chunk, IQueryBuilder::PARAM_INT_ARRAY);
- $result = $query->execute();
660
661
- $unreadComments += array_fill_keys($objectIds, 0);
+ $result = $query->executeQuery();
662
while ($row = $result->fetch()) {
663
$unreadComments[$row['object_id']] = (int) $row['num_comments'];
664
665
+ $result->closeCursor();
666
- $result->closeCursor();
667
668
return $unreadComments;
669
0 commit comments