diff options
author | Gábor Hojtsy <gabor@hojtsy.hu> | 2007-09-27 13:12:26 +0000 |
---|---|---|
committer | Gábor Hojtsy <gabor@hojtsy.hu> | 2007-09-27 13:12:26 +0000 |
commit | b5b6b32e364b87c87e944968764e212e85d2e10e (patch) | |
tree | 477ecd9e6539c7c135ebf84241912946557d9173 | |
parent | 5d5b285ddebc1265073cdbac6e1da64c6245e1f7 (diff) | |
download | brdo-b5b6b32e364b87c87e944968764e212e85d2e10e.tar.gz brdo-b5b6b32e364b87c87e944968764e212e85d2e10e.tar.bz2 |
#158927 by John Morahan: first time, the default admin theme name is '0', so block initialization gives warnings. Avoid this initialization until we have a theme selected
-rw-r--r-- | modules/system/system.module | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/system/system.module b/modules/system/system.module index 3cfdb3eb1..65d6219b8 100644 --- a/modules/system/system.module +++ b/modules/system/system.module @@ -517,7 +517,7 @@ function system_admin_menu_block($item) { function system_admin_theme_submit($form, &$form_state) { // If we're changing themes, make sure the theme has its blocks initialized. - if ($form_state['values']['admin_theme'] != variable_get('admin_theme', '0')) { + if ($form_state['values']['admin_theme'] && $form_state['values']['admin_theme'] != variable_get('admin_theme', '0')) { $result = db_result(db_query("SELECT COUNT(*) FROM {blocks} WHERE theme = '%s'", $form_state['values']['admin_theme'])); if (!$result) { system_initialize_theme_blocks($form_state['values']['admin_theme']); |