diff --git a/styleswitcher.module b/styleswitcher.module
index 7f665c7..33fd4e7 100644
--- a/styleswitcher.module
+++ b/styleswitcher.module
@@ -46,7 +46,12 @@ function styleswitcher_block_view($delta) {
         // Do we want the overlay and fade
         $styleswitcher_enable_overlay = variable_get('styleswitcher_enable_overlay', 1);
         drupal_add_js(array('styleSwitcher' => array('enableOverlay' => $styleswitcher_enable_overlay)), array('type' => 'setting', 'scope' => JS_DEFAULT));
-        $default = $theme_info->info['styleswitcher']['css']['default'];
+        if (!empty($theme_info->info['styleswitcher']['css']['default'])) {
+          $default = $theme_info->info['styleswitcher']['css']['default'];
+        }
+        else {
+          $default = reset($theme_info->info['styleswitcher']['css']);
+        }
         drupal_add_js(array('styleSwitcher' => array('defaultStyle' => $default)), array('type' => 'setting', 'scope' => JS_DEFAULT));
 
         $block['subject'] = t('Style Switcher');
