--- dependent/dependent.module	2008-04-03 01:07:46.000000000 -0700
+++ dependent.module	2008-04-13 18:32:08.000000000 -0700
@@ -32,6 +32,9 @@
       $form['#validate']=array_merge(array('dependent_validate_required_fields'=>array()), $form['#validate']);//add the required field validation to the beginning so it will be called before node_form_validate
     }     
     while ($field=db_fetch_array($dependencies)){      //the while loop is to support future development where a field can be dependent on many parents
+      if (($barpos = strpos($field['option_text'], '|')) !== false) {
+        $field['option_text'] = substr($field['option_text'], 0, $barpos);
+      }
       if (isset($form[$field['child_field_name']])){                                                                                                             
         $suffix=$form[$field['child_field_name']]['#suffix'].'<div class="child_of_'.$field['parent_field_name'].'" style="display: none">child of '.$field['parent_field_name'].($field['put_after_parent']?' put_after_parent':'').(($field['option_text']=='no_value_needed')?'':(' option_text='.$field['option_text'])).'</div>';//this string will help the javascript to hide/show this field
         $form[$field['child_field_name']]['#suffix']=$suffix;
