Twenty Thirteen: Use WP_Theme's methods, rather than legacy properties.

git-svn-id: https://develop.svn.wordpress.org/trunk@24030 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin 2013-04-18 17:10:47 +00:00
parent e414638a7f
commit 71e9178bea

View File

@ -22,8 +22,8 @@
* @return void
*/
function twentythirteen_switch_theme( $theme_name, $theme ) {
if ( 'twentythirteen' != $theme->template )
switch_theme( $theme->template, $theme->stylesheet );
if ( 'twentythirteen' != $theme->get_template() )
switch_theme( $theme->get_template(), $theme->get_stylesheet() );
elseif ( 'twentythirteen' != WP_DEFAULT_THEME )
switch_theme( WP_DEFAULT_THEME );