--- mimemail.module  2009-02-22 02:58:24.000000000 +0100
+++ mimemail.module 2009-03-30 20:33:28.000000000 +0200
@@ -496,10 +496,9 @@ function theme_mimemail_message($body, $
 
   // If we have a $mailkey, check for a mailkey-specific style sheet and
   // set it as a class for <body>.
-  if ($mailkey) {
-    $key = check_plain($mailkey);
+  if (count($mailkey)) {
+    $key = check_plain($mailkey[0]);
     $key = str_replace(' ','-', trim($key));
-    print_r($key); die;
     $styles = drupal_get_path('theme', $theme) .'/mail-'. $key .'.css';
     $class  = ' class="mail-'. $key .'"';
   }

