Index: chessboard.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/chessboard/chessboard.module,v
retrieving revision 1.86
diff -u -p -r1.86 chessboard.module
--- chessboard.module	18 Feb 2011 22:28:36 -0000	1.86
+++ chessboard.module	1 Mar 2011 11:26:27 -0000
@@ -11,13 +11,13 @@ function chessboard_process_chessboard_n
     $params =& $matches[1];
 
     // Number of files: any integer (default: 8)
-    $item['file_max'] = preg_match('@[0-9]+@', $params, $m) ? $m[0] : 8;
+    $elements[$delta]['#file_max'] = preg_match('@[0-9]+@', $params, $m) ? $m[0] : 8;
 
     // Color of the upper left square: [l]ight (default), or [d]ark
-    $item['square_color_first'] = (strpos($params, 'd') !== FALSE) ? 1 : 0;
+    $elements[$delta]['#square_color_first'] = (strpos($params, 'd') !== FALSE) ? 1 : 0;
 
     // Borders
-    $item['border'] = array('T' => (strpos($params, 'T') !== FALSE),
+    $elements[$delta]['#border'] = array('T' => (strpos($params, 'T') !== FALSE),
                     'B' => (strpos($params, 'B') !== FALSE),
                     'L' => (strpos($params, 'L') !== FALSE),
                     'R' => (strpos($params, 'R') !== FALSE));
@@ -26,7 +26,7 @@ function chessboard_process_chessboard_n
     //----------------------------------
     $board_value =& $matches[2];
     $board_value = strip_tags($board_value);
-    $item['board'] = array();
+    $elements[$delta]['#board'] = array();
     $file = $rank_d = 0;
     for ($i=0; isset($board_value[$i]); $i++) {
       // Ignore unknown characters
@@ -34,7 +34,7 @@ function chessboard_process_chessboard_n
         continue;
       }
 
-      if ($file >= $item['file_max']) {
+      if ($file >= $elements[$delta]['#file_max']) {
         $file = 0;
         $rank_d++;
       }
@@ -42,16 +42,15 @@ function chessboard_process_chessboard_n
       if (strpos('12345678', $board_value[$i]) !== FALSE) {
         // Multiple empty squares
         for ($j=0; $j<$board_value[$i]; $j++) {
-          $item['board'][$rank_d][$file] = '-';
+          $elements[$delta]['#board'][$rank_d][$file] = '-';
           $file++;
         }
       }
       else {
-        $item['board'][$rank_d][$file] = $board_value[$i];
+        $elements[$delta]['#board'][$rank_d][$file] = $board_value[$i];
         $file++;
       }
     }
-    $elements[$delta]['#item'] = $item;
   }
   return $elements;
 }
Index: chessboard_render.php
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/chessboard/chessboard_render.php,v
retrieving revision 1.33
diff -u -p -r1.33 chessboard_render.php
--- chessboard_render.php	1 Jan 2011 22:17:29 -0000	1.33
+++ chessboard_render.php	1 Mar 2011 11:26:28 -0000
@@ -143,8 +143,8 @@ function template_preprocess_chessboard(
   }
   $variables['table_xhtml'] = $tables_xhtml[$image_directory_path];
   // For convenience.
-  $variables['file_max'] = $variables['element']['#item']['file_max'];
-  $variables['square_color_first'] = $variables['element']['#item']['square_color_first'];
-  $variables['border'] = $variables['element']['#item']['border'];
-  $variables['board'] = $variables['element']['#item']['board'];
+  $variables['file_max'] = $variables['element']['#file_max'];
+  $variables['square_color_first'] = $variables['element']['#square_color_first'];
+  $variables['border'] = $variables['element']['#border'];
+  $variables['board'] = $variables['element']['#board'];
 }
