diff options
Diffstat (limited to 'templates/actor_profile_page.php')
| -rw-r--r-- | templates/actor_profile_page.php | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/templates/actor_profile_page.php b/templates/actor_profile_page.php index e7d28b7..649069d 100644 --- a/templates/actor_profile_page.php +++ b/templates/actor_profile_page.php @@ -9,11 +9,16 @@ call_template('skeleton', [ global $actor; call_template('actor_profile', ['actor' => $actor]); echo '<hr>'; - $notes = Note::findAllWithAuthor($actor, 50); + $notes = Note::findAllWithAuthor($actor, 20); if (count($notes) == 0) { call_template('placeholder_text', ['message' => __('user.notes.placeholder')]); - } - foreach ($notes as $n) { - call_template('note', ['note' => $n]); + } else { + foreach ($notes as $n) { + call_template('note', ['note' => $n]); + } + $countNotShown = Note::countWithAuthor($actor) - count($notes); + if ($countNotShown >= 0) { + call_template('placeholder_text', ['count' => $countNotShown]); + } } });
\ No newline at end of file |
