Uma área de pesquisa sobre o WordPress para devs e autores do tema



wp_defer_term_counting ›

Desde2.5.0
Obsoleton/a
wp_defer_term_counting ( $defer = null )
Parâmetros:
  • (bool) $defer Optional. Enable if true, disable if false.
    Required: No
    Padrão: null
Retorna:
  • (bool) Whether term counting is enabled or disabled.
Definido em:
Codex:

Enable or disable term counting.



Fonte

function wp_defer_term_counting( $defer = null ) {
	static $_defer = false;

	if ( is_bool( $defer ) ) {
		$_defer = $defer;
		// flush any deferred counts
		if ( ! $defer ) {
			wp_update_term_count( null, null, true );
		}
	}

	return $_defer;
}