# This patch file was generated by NetBeans IDE
# This patch can be applied using context Tools: Apply Diff Patch action on respective folder.
# It uses platform neutral UTF-8 encoding.
# Above lines and this line are ignored by the patching process.
Index: millennium.module
--- millennium.module Base (1.13.2.33.2.2.2.94)
+++ millennium.module Locally Modified (Based On 1.13.2.33.2.2.2.94)
@@ -788,7 +788,7 @@
       if (sizeof($node->millennium_biblio_data['authors']) > 0) {
         $authors_output += $node->millennium_biblio_data['authors'];
       }
-      $author_fields = explode('|', 'secondary_authors|tertiary_authors|corp_author');
+      $author_fields = array('secondary_authors', 'tertiary_authors', 'corp_author');
       foreach ($author_fields as $field) {
         $author = $node->millennium_biblio_data[$field];
         if (sizeof($author) > 0) {
@@ -1816,7 +1816,7 @@
 
   // Define repeatable fields
   $biblio_repeatable = array(
-    'isbn', 'issn', 'authors', 'corp_author', 'alternate_title', 'series'
+    'isbn', 'issn', 'authors', 'corp_author', 'secondary_authors', 'tertiary_authors', 'alternate_title', 'series'
   );
 
   foreach ($tags as $fieldname => $tag) {
@@ -1856,16 +1856,18 @@
   }
 
   // Check if author found
-  if ($biblio["authors"] == "") {
+  if (!$biblio["authors"]) {
     if ($biblio["corp_author"]) {
       $biblio["authors"] = $biblio["corp_author"];
       unset($biblio["corp_author"]);
     }
-    else {
-      if ($biblio["secondary_authors"]) {
+    elseif ($biblio["secondary_authors"]) {
         $biblio["authors"] = $biblio["secondary_authors"];
         unset($biblio["secondary_authors"]);
       }
+    elseif ($biblio["tertiary_authors"]) {
+      $biblio["authors"] = $biblio["tertiary_authors"];
+      unset($biblio["tertiary_authors"]);
     }
   }
 
@@ -2056,21 +2058,15 @@
   }
 
   // Authors
-  $author_fields = explode('|', 'authors|secondary_authors|tertiary_authors|corp_author');
-  unset($authors);
+  $author_fields = array('authors', 'secondary_authors', 'tertiary_authors', 'corp_author');
+  $authors = array();
   foreach ($author_fields as $field) {
     $value = $nodeobject->millennium_biblio_data[$field];
-    if ($value != "")
-      if (strpos($value, ";")) {
-        $tmp = explode(';', $value);
-        foreach ($tmp as $author)
-          $authors[] = $author;
+    if ($value) {
+      $authors += $value;
       }
-      else {
-        $authors[] = $value;
       }
-  }
-  if (is_array($authors)) {
\ No newline at end of file
+  if ($authors) {
\ No newline at end of file
     millennium_add_node_taxonomy_terms($nodeobject, variable_get('millennium_marc_vid_author', -1), $authors);
   }
 
