WPSEO_Option_MS::__construct()publicYoast 1.0

Only run parent constructor in multisite context.

Метод класса: WPSEO_Option_MS{}

Хуков нет.

Возвращает

null. Ничего (null).

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

$WPSEO_Option_MS = new WPSEO_Option_MS();
$WPSEO_Option_MS->__construct();

Код WPSEO_Option_MS::__construct() Yoast 24.9

public function __construct() {
	$allow_prefix   = self::ALLOW_KEY_PREFIX;
	$this->defaults = [
		'access'                                            => 'admin',
		'defaultblog'                                       => '', // Numeric blog ID or empty.
		"{$allow_prefix}disableadvanced_meta"               => true,
		"{$allow_prefix}ryte_indexability"                  => false,
		"{$allow_prefix}content_analysis_active"            => true,
		"{$allow_prefix}keyword_analysis_active"            => true,
		"{$allow_prefix}inclusive_language_analysis_active" => true,
		"{$allow_prefix}enable_admin_bar_menu"              => true,
		"{$allow_prefix}enable_cornerstone_content"         => true,
		"{$allow_prefix}enable_xml_sitemap"                 => true,
		"{$allow_prefix}enable_text_link_counter"           => true,
		"{$allow_prefix}enable_headless_rest_endpoints"     => true,
		"{$allow_prefix}enable_metabox_insights"            => true,
		"{$allow_prefix}enable_link_suggestions"            => true,
		"{$allow_prefix}tracking"                           => true,
		"{$allow_prefix}enable_enhanced_slack_sharing"      => true,
		"{$allow_prefix}semrush_integration_active"         => true,
		"{$allow_prefix}wincher_integration_active"         => false,
		"{$allow_prefix}remove_feed_global"                 => true,
		"{$allow_prefix}remove_feed_global_comments"        => true,
		"{$allow_prefix}remove_feed_post_comments"          => true,
		"{$allow_prefix}enable_index_now"                   => true,
		"{$allow_prefix}enable_ai_generator"                => true,
		"{$allow_prefix}remove_feed_authors"                => true,
		"{$allow_prefix}remove_feed_categories"             => true,
		"{$allow_prefix}remove_feed_tags"                   => true,
		"{$allow_prefix}remove_feed_custom_taxonomies"      => true,
		"{$allow_prefix}remove_feed_post_types"             => true,
		"{$allow_prefix}remove_feed_search"                 => true,
		"{$allow_prefix}remove_atom_rdf_feeds"              => true,
		"{$allow_prefix}remove_shortlinks"                  => true,
		"{$allow_prefix}remove_rest_api_links"              => true,
		"{$allow_prefix}remove_rsd_wlw_links"               => true,
		"{$allow_prefix}remove_oembed_links"                => true,
		"{$allow_prefix}remove_generator"                   => true,
		"{$allow_prefix}remove_emoji_scripts"               => true,
		"{$allow_prefix}remove_powered_by_header"           => true,
		"{$allow_prefix}remove_pingback_header"             => true,
		"{$allow_prefix}clean_campaign_tracking_urls"       => true,
		"{$allow_prefix}clean_permalinks"                   => true,
		"{$allow_prefix}search_cleanup"                     => true,
		"{$allow_prefix}search_cleanup_emoji"               => true,
		"{$allow_prefix}search_cleanup_patterns"            => true,
		"{$allow_prefix}redirect_search_pretty_urls"        => true,
		"{$allow_prefix}algolia_integration_active"         => true,
	];

	if ( is_multisite() ) {
		parent::__construct();

		add_filter( 'admin_title', [ 'Yoast_Input_Validation', 'add_yoast_admin_document_title_errors' ] );
	}
}