Commit 6890815a by pupi1985

Fix another PHP 7.2 count warning

parent c2da0046
......@@ -381,8 +381,8 @@ function qa_post_html_fields($post, $userid, $cookieid, $usershtml, $dummy, $opt
if (@$options['categoryview'] && isset($post['categoryname']) && isset($post['categorybackpath'])) {
$favoriteclass = '';
if (count(@$favoritemap['category'])) {
if (@$favoritemap['category'][$post['categorybackpath']]) {
if (isset($favoritemap['category']) && !empty($favoritemap['category'])) {
if (isset($favoritemap['category'][$post['categorybackpath']])) {
$favoriteclass = ' qa-cat-favorited';
} else {
foreach ($favoritemap['category'] as $categorybackpath => $dummy) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment