function wp_defer_term_counting($defer=null) {}

Enable or disable term counting.


  • bool $defer: Optional. Enable if true, disable if false.

Return values

returns:Whether term counting is enabled or disabled.

Source code

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;



No comments yet... Be the first to leave a reply!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: