[WordPress]コンテンツエディタ削除

/* ===============================================
# エディタ削除
=============================================== */

function top_disable_block_editor($use_block_editor, $post){
	$post_type = $post->post_type;
	$post_name = $post->post_name;

	if($post_type === 'post' || $post_type === 'directsalon') return false;
	return $use_block_editor;
}
add_filter( 'use_block_editor_for_post', 'top_disable_block_editor', 10, 2 );