summaryrefslogtreecommitdiff
path: root/actions/public.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/public.php')
-rw-r--r--actions/public.php16
1 files changed, 5 insertions, 11 deletions
diff --git a/actions/public.php b/actions/public.php
index 8a41dcd56..218f80194 100644
--- a/actions/public.php
+++ b/actions/public.php
@@ -54,7 +54,6 @@ class PublicAction extends StreamAction {
$this->public_views_menu();
-
$this->show_feeds_list(array(0=>array('href'=>common_local_url('publicrss'),
'type' => 'rss',
'version' => 'RSS 1.0',
@@ -87,18 +86,13 @@ class PublicAction extends StreamAction {
$notice = Notice::publicStream(($page-1)*NOTICES_PER_PAGE,
NOTICES_PER_PAGE + 1);
- if ($notice) {
- common_element_start('ul', array('id' => 'notices'));
- while ($notice->fetch()) {
- $cnt++;
- if ($cnt > NOTICES_PER_PAGE) {
- break;
- }
- $this->show_notice($notice);
- }
- common_element_end('ul');
+ if (!$notice) {
+ $this->server_error(_('Could not retrieve public stream.'));
+ return;
}
+ $cnt = $this->show_notice_list($notice);
+
common_pagination($page > 1, $cnt > NOTICES_PER_PAGE,
$page, 'public');
}