wpseek.com
A WordPress-centric search engine for devs and theme authors



get_broken_themes › WordPress Function

Since1.5.0
Deprecated3.4.0
get_broken_themes ( No parameters )
See:
Returns:
  • (array)
Defined at:
Codex:

Retrieves a list of broken themes.



Source

function get_broken_themes() {
	_deprecated_function( __FUNCTION__, '3.4.0', "wp_get_themes( array( 'errors' => true )" );

	$themes = wp_get_themes( array( 'errors' => true ) );
	$broken = array();
	foreach ( $themes as $theme ) {
		$name = $theme->get('Name');
		$broken[ $name ] = array(
			'Name' => $name,
			'Title' => $name,
			'Description' => $theme->errors()->get_error_message(),
		);
	}
	return $broken;
}