diff --git a/htdocs/wp-content/themes/lawcarta/functions.php b/htdocs/wp-content/themes/lawcarta/functions.php index a83113e..acc5e04 100644 --- a/htdocs/wp-content/themes/lawcarta/functions.php +++ b/htdocs/wp-content/themes/lawcarta/functions.php @@ -176,7 +176,7 @@ function getFaaTaxonomyIds() $tIds = []; foreach ($posts as $post) { $taxonomies = get_the_terms($post, 'fac_category_type'); - if (count($taxonomies) > 0) { + if (is_countable($taxonomies) && count($taxonomies) > 0) { foreach ($taxonomies as $taxonomy) { if (!in_array($taxonomy->term_id, $tIds)) { $tIds[] = $taxonomy->term_id;