Commit 98a64897 authored by prrw's avatar prrw Committed by GitHub

Fixed bug in xmlparser.py (Issue #1324) (#1325)

* Update xmlparser.py

* Update xmlparser.py
parent 244f08ef
......@@ -459,7 +459,9 @@ class XMLParser:
date_time = model.attrib.get('PublicationDate')
if date_time is None:
date_time = ua.DateTime(1, 1, 1)
else:
elif date_time is not None and date_time[-1]=="Z":
date_time = ua.DateTime.strptime(date_time, "%Y-%m-%dT%H:%M:%SZ")
else:
date_time = ua.DateTime.strptime(date_time, "%Y-%m-%dT%H:%M:%S%z")
ns.append((uri, version, date_time))
return ns
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment