diff options
Diffstat (limited to 'src/web/_views/comments.php')
-rw-r--r-- | src/web/_views/comments.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/web/_views/comments.php b/src/web/_views/comments.php index 7f8acf2..0544f84 100644 --- a/src/web/_views/comments.php +++ b/src/web/_views/comments.php @@ -1,6 +1,7 @@ <?php /* Copyright (c) 2024 Freya Murphy */ ?> <?=aria_section('comments', lang('comments'))?> <?php + if ($comments) foreach($comments as $comment) { $date = $this->main->format_date($comment['created']); @@ -10,7 +11,7 @@ echo '<p class="content">' . esc($comment['content']) . '</p>'; echo '</div>'; } - if (!count($comments)) { + if (!$comments || !count($comments)) { echo '<span>'. lang('no_comments') .'</span>'; } ?> |