--- template.php	2008-12-08 21:43:46.000000000 +0200
+++ template-01.php	2009-04-22 11:19:37.000000000 +0300
@@ -94,6 +94,7 @@ function tendu_i18n_link($text, $target,
  *   A sequential array of variables to pass to the theme template.
  */
 function _phptemplate_variables($hook, $vars=array() ) {
+  global $user;
   switch ($hook) {
     case 'page':
       /* Add classes to the "body" tag, for easier layout styling
@@ -101,7 +102,7 @@ function _phptemplate_variables($hook, $
       */
       $body_classes = array();
       // Page user is logged in
-      $body_classes[] = ($vars['logged_in']) ? 'logged-in' : 'not-logged-in';
+      $body_classes[] = ($user->uid) ? 'logged-in' : 'not-logged-in';
       // Page is front page
       $body_classes[] = ($vars['is_front']) ? 'front' : 'not-front'; 
       
