Skip to content

Commit 83aa8eb

Browse files
committed
minor fix for missing type in config
1 parent df60aa7 commit 83aa8eb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

csv2cmi.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
from xml.dom import minidom
2020

2121
__license__ = "MIT"
22-
__version__ = '1.3.2'
22+
__version__ = '1.3.3'
2323

2424
# define log output
2525
logging.basicConfig(format='%(levelname)s: %(message)s')
@@ -91,6 +91,7 @@ def createTextstructure():
9191
p = SubElement(body, 'p')
9292
return text
9393

94+
9495
def createFileDesc(config):
9596
# creates a file description from config file
9697
fileDesc = Element('fileDesc')
@@ -110,7 +111,7 @@ def createFileDesc(config):
110111
else:
111112
publisher.text = config.get('Project', 'editor')
112113
idno = SubElement(publicationStmt, 'idno')
113-
idno.set('type', 'URL')
114+
idno.set('type', 'url')
114115
idno.text = config.get('Project', 'fileURL', fallback=os.path.splitext(
115116
os.path.basename(args.filename))[0] + '.xml')
116117
date = SubElement(publicationStmt, 'date')
@@ -226,10 +227,9 @@ def createPlace(placestring):
226227

227228
def createEdition(editionTitle, biblID):
228229
# creates a new bibliographic entry
230+
editionType = 'print'
229231
if ('Edition' in config) and ('type' in config['Edition']):
230232
editionType = config.get('Edition', 'type')
231-
if not editionType:
232-
editionType = 'print'
233233
bibl = Element('bibl')
234234
bibl.text = editionTitle
235235
bibl.set('type', editionType)

0 commit comments

Comments
 (0)