lib/dwc-archive/classification_normalizer.rb in dwc-archive-0.5.15 vs lib/dwc-archive/classification_normalizer.rb in dwc-archive-0.5.16

- old
+ new

@@ -87,13 +87,13 @@ add_name_string(synonym.canonical_name) end def set_scientific_name(row, fields) row[fields[:scientificname]] = 'N/A' unless row[fields[:scientificname]] - canonical_name = fields[:scientificnameauthorship] ? row[fields[:scientificname]] : get_canonical_name(row[fields[:scientificname]]) + canonical_name = get_canonical_name(row[fields[:scientificname]]) fields[:canonicalname] = row.size row << canonical_name - scientific_name = (fields[:scientificnameauthorship] && row[fields[:scientificnameauthorship]].to_s.strip != '') ? row[fields[:scientificname]].strip + ' ' + row[fields[:scientificnameauthorship]].strip : row[fields[:scientificname]].strip + scientific_name = row[fields[:scientificname]].strip row[fields[:scientificname]] = scientific_name end def ingest_core raise RuntimeError, "Darwin Core core fields must contain taxon id and scientific name" unless (@core_fields[:id] && @core_fields[:scientificname])