Yoast\WP\SEO\Bulk_Editor\Infrastructure\Updates

Post_Access_Checker::exists │ public │ Yoast 1.0

Whether the post exists.

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

Хуков нет.

Возвращает

bool. Whether the post exists.

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

$Post_Access_Checker = new Post_Access_Checker();
$Post_Access_Checker->exists( $post_id ): bool;
$post_id(int) (обязательный)
The ID of the post.

Код Post_Access_Checker::exists() Yoast 28.8

public function exists( int $post_id ): bool {
	return \get_post( $post_id ) !== null;
}