WP_REST_Themes_Controller::is_same_theme( WP_Theme $theme_a, WP_Theme $theme_b ): bool

In this article

Helper function to compare two themes.

Parameters

$theme_aWP_Themerequired
First theme to compare.
$theme_bWP_Themerequired
Second theme to compare.

Return

bool

Source

protected function is_same_theme( $theme_a, $theme_b ) {
	return $theme_a->get_stylesheet() === $theme_b->get_stylesheet();
}

Changelog

VersionDescription
5.7.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.