Yoast\WP\SEO\Alerts\Application\Default_SEO_Data

Default_SEO_Data_Alert::get_default_seo_data_notification │ private │ Yoast 1.0

Build the default SEO data notification.

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

Хуков нет.

Возвращает

Yoast_Notification. The notification containing the suggested plugin.

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

// private - только в коде основоного (родительского) класса
$result = $this->get_default_seo_data_notification( $has_enough_posts_with_default_title, $has_enough_posts_with_default_desc ): Yoast_Notification;
$has_enough_posts_with_default_title(true|false) (обязательный)
Whether there are content types with default SEO title in their most recent posts.
$has_enough_posts_with_default_desc(true|false) (обязательный)
Whether there are content types with default SEO description in their most recent posts.

Код Default_SEO_Data_Alert::get_default_seo_data_notification() Yoast 28.9

private function get_default_seo_data_notification( $has_enough_posts_with_default_title, $has_enough_posts_with_default_desc ): Yoast_Notification {
	$message = $this->get_default_seo_data_message( $has_enough_posts_with_default_title, $has_enough_posts_with_default_desc );

	return new Yoast_Notification(
		$message,
		[
			'id'           => self::NOTIFICATION_ID,
			'type'         => Yoast_Notification::WARNING,
			'capabilities' => [ 'wpseo_manage_options' ],
		],
	);
}