commit ceace252f324d1c1e8c63c1f2b40a0a0355fec2e
Author: Quentin Albrand <quentin.albrand@gmail.com>
Date:   Thu Apr 26 15:56:56 2012 +0200

    Creating a patch for #1548428

diff --git a/plugins/sweaver_plugin_customcss/sweaver_plugin_customcss.inc b/plugins/sweaver_plugin_customcss/sweaver_plugin_customcss.inc
new file mode 100644
index 0000000..5b9c19e
--- /dev/null
+++ b/plugins/sweaver_plugin_customcss/sweaver_plugin_customcss.inc
@@ -0,0 +1,8 @@
+<?php 
+
+class sweaver_plugin_customcss extends sweaver_plugin {
+    
+
+}
+
+?>
\ No newline at end of file
diff --git a/sweaver.registry.inc b/sweaver.registry.inc
index 3ee9b35..37c13f7 100644
--- a/sweaver.registry.inc
+++ b/sweaver.registry.inc
@@ -29,6 +29,7 @@ function _sweaver_menu() {
   );
 
   $sweaver = Sweaver::get_instance();
+  $rebuild_registry = false;
   foreach (array_keys($sweaver->get_plugins_registry(TRUE)) as $plugin_name) {
     $sweaver_plugin = $sweaver->get_plugin($plugin_name);
     $page_arguments = array(
@@ -39,8 +40,15 @@ function _sweaver_menu() {
       $item = $sweaver_plugin->sweaver_menu($weight, $page_arguments, $base);
       $items += $item;
     }
-    
+    else {
+      $rebuild_registry = true;
+    }
+  }
+  
+  if ($rebuild_registry) {
+    drupal_theme_rebuild();
   }
+  
   return $items;
 }
 
@@ -68,7 +76,7 @@ function _sweaver_theme() {
   $sweaver = Sweaver::get_instance();
   foreach (array_keys($sweaver->get_plugins_registry(TRUE)) as $plugin_name) {
     $sweaver_plugin = $sweaver->get_plugin($plugin_name);
-    // Allow drupal to load even if sweaver update process gone wrong
+    // Allow drupal to load even if sweaver update process gone wrong    
     if (is_object($sweaver_plugin)) {
       $theme_function = $sweaver_plugin->sweaver_theme();
       $theme_functions += $theme_function;
