Yoast\WP\SEO\Helpers

Wordproof_Helper::is_active()publicYoast 1.0

Return if WordProof should be active for this post editor page.

{} Это метод класса: Wordproof_Helper{}

Хуков нет.

Возвращает

true|false. Returns if WordProof should be active for this page.

Использование

$Wordproof_Helper = new Wordproof_Helper();
$Wordproof_Helper->is_active();

Код Wordproof_Helper::is_active() Yoast 19.7.1

public function is_active() {
	$is_wordproof_active = $this->integration_is_active();

	if ( ! $is_wordproof_active ) {
		return false;
	}

	$user_can_publish = ( new User_Can_Publish_Posts_And_Pages_Conditional() )->is_met();

	if ( ! $user_can_publish ) {
		return false;
	}

	return ( $this->current_page->current_post_is_privacy_policy() || $this->woocommerce->current_post_is_terms_and_conditions_page() );
}