mirror of
https://github.com/WordPress/WordPress.git
synced 2024-11-12 13:44:21 +01:00
Revert to WP_DEFAULT_THEME if a child theme is in use and no style.css is present. fixes #15712.
git-svn-id: http://svn.automattic.com/wordpress/trunk@16924 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
1050da7bce
commit
3efc0738b6
@ -1287,6 +1287,11 @@ function validate_current_theme() {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ( is_child_theme() && ! file_exists( get_stylesheet_directory() . '/style.css' ) ) {
|
||||||
|
switch_theme( WP_DEFAULT_THEME, WP_DEFAULT_THEME );
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user