--- /home/cwells/Desktop/views_groupby_pack/taxonomygroup.inc	2008-03-11 19:11:31.000000000 -0400
+++ /var/www/dmi/sites/default/modules/views_groupby_pack/taxonomygroup.inc	2008-05-02 16:04:52.000000000 -0400
@@ -6,7 +6,7 @@
 
 function theme_taxonomygroup_group_teaser($view, $nodes, $type) {
   return theme("taxonomygroup_group", $view, $nodes, $type, true);
-} // funciton theme_taxonomygroup_taxonomygroup_teaser
+} // function theme_taxonomygroup_taxonomygroup_teaser
 
 
 function theme_taxonomygroup_group($view, $nodes, $type, $teaser=false) {
@@ -22,11 +22,18 @@ function theme_taxonomygroup_group($view
   } // if the sort field isn't set
 
   $by_taxonomy = array();
+  $done = array();
+  
   foreach ($nodes as $proto_node) {
-    $node = node_load($proto_node->nid);
-    $val = array_values($node->taxonomy);
-    $term = $val[0]->name;
-    $by_taxonomy[$term][] = $node;
+    if (!in_array($proto_node->nid, $done)) {
+      $node = node_load($proto_node->nid);
+      $val = array_values($node->taxonomy);
+      foreach($val as $cat) {
+        $term = $cat->name;
+        $by_taxonomy[$term][] = $node;
+      }
+      $done[] = $proto_node->nid;
+    }    
   } // foreach node
 
   return theme("taxonomygroup_taxonomygroup", $view, $by_taxonomy, $type, $teaser);
