Skip to content

Commit

Permalink
Fixes #16: define constant only once
Browse files Browse the repository at this point in the history
  • Loading branch information
atz committed Feb 5, 2015
1 parent f06f4c9 commit 6aa2594
Showing 1 changed file with 7 additions and 8 deletions.
15 changes: 7 additions & 8 deletions lib/mods/nom_terminology.rb
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
module Mods

# from: http://www.loc.gov/standards/mods/v3/mods-userguide-generalapp.html

LANG_ATTRIBS = ['script', 'transliteration']

if Nokogiri::VERSION < "1.6.6"
# Nokogiri 1.6.6 introduced lang as a built-in attribute
LANG_ATTRIBS += ['lang']
end

# Nokogiri 1.6.6 introduced lang as a built-in attribute
LANG_ATTRIBS = (Nokogiri::VERSION < "1.6.6") ?
['script', 'transliteration', 'lang'] :
['script', 'transliteration']

LINKING_ATTRIBS = ['xlink', 'ID']

DATE_ATTRIBS = ['encoding', 'point', 'keyDate', 'qualifier']
Expand Down

0 comments on commit 6aa2594

Please sign in to comment.