sm_sitemap_taxonomy_hide_empty

sm_sitemap_taxonomy_hide_empty

Hook Type: filter

See hook in core

Displaying hooks found in version: google-sitemap-generator.4.1.21

apply_filters('sm_sitemap_taxonomy_hide_empty') is found 2 times:

  • /class-googlesitemapgeneratorstandardbuilder.php line 634
    				'number'		=> $links_per_page,
    				'offset'		=> $offset,
    				'exclude'		=> $excludes,
    			];
    			$queryArr['hide_empty'] = apply_filters( 'sm_sitemap_taxonomy_hide_empty', true );
    			if (preg_match('/(post_tag|category)/', $taxonomy)) {
    				$queryArr['hierarchical'] = false;
    			}
    			$terms = array_values(
    				array_unique(
    					array_filter(
    
  • /class-googlesitemapgeneratorstandardbuilder.php line 908
    				$terms_args = [
    					'taxonomy' => $taxonomy,
    					'exclude' => $excludes
    				];
    				$terms_args['hide_empty'] = apply_filters( 'sm_sitemap_taxonomy_hide_empty', true );
    				$terms = $this->get_terms( $terms_args );
    				$terms_by_taxonomy[ $taxonomy ] = $terms;
    			}
    		}
    
    		foreach ( $terms_by_taxonomy as $taxonomy => $terms ) {