| @@ -59,8 +59,14 @@ | ||
| 59 | 59 | $docs_query_args = ! isset( $docs_query_args ) ? $_docs_query_args : wp_parse_args( $docs_query_args, $_docs_query_args ); |
| 60 | 60 | |
| 61 | 61 | $terms_count = count( $terms ); |
| 62 | 62 | $terms_number = 1; |
| 63 | + | |
| 64 | + $_term_ids = wp_list_pluck( $terms, 'term_id' ); | |
| 65 | + if ( ! empty( $_term_ids ) ) { | |
| 66 | + update_termmeta_cache( $_term_ids ); | |
| 67 | + } | |
| 68 | + | |
| 63 | 69 | foreach ( $terms as $term ) { |
| 64 | 70 | $_counts = betterdocs()->query->get_docs_count( |
| 65 | 71 | $term, |
| 66 | 72 | $nested_subcategory, |