]> git.mxchange.org Git - friendica.git/commitdiff
Initialize array
authorMichael <heluecht@pirati.ca>
Wed, 13 Sep 2023 04:38:04 +0000 (04:38 +0000)
committerMichael <heluecht@pirati.ca>
Wed, 13 Sep 2023 04:38:04 +0000 (04:38 +0000)
src/Module/Conversation/Timeline.php

index 0456c8e1d06cf081eb2161f6c18f07630997f92a..5ee5a7b674d6a8080f322cb2950b1721e17a0c40 100644 (file)
@@ -203,6 +203,7 @@ class Timeline extends BaseModule
 
                        while (count($selected_items) < $this->itemsPerPage && ++$count < 50 && count($items) > 0) {
                                foreach ($items as $item) {
+                                       $numposts[$item['owner-id']] = ($numposts[$item['owner-id']] ?? 0);
                                        if (!in_array($item['owner-id'], $reduced) || (($numposts[$item['owner-id']]++ < $maxpostperauthor)) && (count($selected_items) < $this->itemsPerPage)) {
                                                $selected_items[] = $item;
                                        }