diff options
author | Dries Buytaert <dries@buytaert.net> | 2009-04-21 09:31:31 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2009-04-21 09:31:31 +0000 |
commit | 3fbda2307d765dde813a8cf09a01f04cd9b65ca1 (patch) | |
tree | ca9fd1435592944e4ede208c16578444ed92b906 /modules/system/system.admin.inc | |
parent | a7c324f42c942eb7728639ec1a58e78134d46eb1 (diff) | |
download | brdo-3fbda2307d765dde813a8cf09a01f04cd9b65ca1.tar.gz brdo-3fbda2307d765dde813a8cf09a01f04cd9b65ca1.tar.bz2 |
- Patch #375482 by mfb: avoid PDO exceptions when block module is not enabled.
Diffstat (limited to 'modules/system/system.admin.inc')
-rw-r--r-- | modules/system/system.admin.inc | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/modules/system/system.admin.inc b/modules/system/system.admin.inc index 481355b40..33b5aa390 100644 --- a/modules/system/system.admin.inc +++ b/modules/system/system.admin.inc @@ -253,7 +253,6 @@ function system_themes_form_submit($form, &$form_state) { foreach ($form_state['values']['status'] as $key => $choice) { // Always enable the default theme, despite its status checkbox being checked: if ($choice || $form_state['values']['theme_default'] == $key) { - system_initialize_theme_blocks($key); $new_theme_list[] = $key; db_query("UPDATE {system} SET status = 1 WHERE type = 'theme' and name = '%s'", $key); } @@ -266,13 +265,6 @@ function system_themes_form_submit($form, &$form_state) { '%selected_theme' => $form_state['values']['theme_default'], ))); } - if ($form_state['values']['admin_theme'] && $form_state['values']['admin_theme'] != variable_get('admin_theme', 0)) { - // If we're changing themes, make sure the theme has its blocks initialized. - $result = db_result(db_query("SELECT COUNT(*) FROM {block} WHERE theme = '%s'", $form_state['values']['admin_theme'])); - if (!$result) { - system_initialize_theme_blocks($form_state['values']['admin_theme']); - } - } // Save the variables. variable_set('theme_default', $form_state['values']['theme_default']); |