Paging fix for threaded notice lists
This commit is contained in:
parent
e89bffc3f1
commit
3b456b4ffe
|
@ -69,6 +69,12 @@ class ThreadedNoticeList extends NoticeList
|
||||||
$cnt = 0;
|
$cnt = 0;
|
||||||
$conversations = array();
|
$conversations = array();
|
||||||
while ($this->notice->fetch() && $cnt <= NOTICES_PER_PAGE) {
|
while ($this->notice->fetch() && $cnt <= NOTICES_PER_PAGE) {
|
||||||
|
$cnt++;
|
||||||
|
|
||||||
|
if ($cnt > NOTICES_PER_PAGE) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
$convo = $this->notice->conversation;
|
$convo = $this->notice->conversation;
|
||||||
if (!empty($conversations[$convo])) {
|
if (!empty($conversations[$convo])) {
|
||||||
// Seen this convo already -- skip!
|
// Seen this convo already -- skip!
|
||||||
|
@ -86,12 +92,6 @@ class ThreadedNoticeList extends NoticeList
|
||||||
$notice->limit(1);
|
$notice->limit(1);
|
||||||
$notice->find(true);
|
$notice->find(true);
|
||||||
|
|
||||||
$cnt++;
|
|
||||||
|
|
||||||
if ($cnt > NOTICES_PER_PAGE) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
try {
|
try {
|
||||||
$item = $this->newListItem($notice);
|
$item = $this->newListItem($notice);
|
||||||
$item->show();
|
$item->show();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user