mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-11 12:20:22 +00:00
Add switch_theme action. Cleanup staticize-reloaded's cache when theme is switched.
git-svn-id: https://develop.svn.wordpress.org/trunk@1755 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -743,12 +743,14 @@ function validate_current_theme() {
|
||||
if (($template != 'default') && (! file_exists("$theme_root/$template/index.php"))) {
|
||||
update_option('template', 'default');
|
||||
update_option('stylesheet', 'default');
|
||||
do_action('switch_theme', 'Default');
|
||||
return false;
|
||||
}
|
||||
|
||||
if (($stylesheet != 'default') && (! file_exists("$theme_root/$stylesheet/style.css"))) {
|
||||
update_option('template', 'default');
|
||||
update_option('stylesheet', 'default');
|
||||
do_action('switch_theme', 'Default');
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user