diff options
Diffstat (limited to '')
-rw-r--r-- | include/category_default.inc.php | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/category_default.inc.php b/include/category_default.inc.php index 40e5b6814..1133c2b00 100644 --- a/include/category_default.inc.php +++ b/include/category_default.inc.php @@ -104,6 +104,11 @@ foreach ($pictures as $row) array('start') ); + if (isset($nb_comments_of) ) + { + $row['nb_comments'] = (int)@$nb_comments_of[$row['id']]; + } + $tpl_var = array( 'ID' => $row['id'], @@ -166,9 +171,9 @@ foreach ($pictures as $row) $tpl_var['NAME'] = $name; - if ( isset($nb_comments_of) ) + if (isset($row['nb_comments'])) { - $tpl_var['NB_COMMENTS'] = (int)@$nb_comments_of[$row['id']]; + $tpl_var['NB_COMMENTS'] = $row['nb_comments']; } $tpl_thumbnails_var[] = $tpl_var; |