Treat a timestamp that can't be parse as if it didn't exist.
This commit is contained in:
parent
d77fb110fb
commit
dcac9dfeca
1 changed files with 5 additions and 2 deletions
|
@ -101,8 +101,11 @@ module OSM
|
||||||
|
|
||||||
parser.listen( :characters, %w{ time } ) do |text|
|
parser.listen( :characters, %w{ time } ) do |text|
|
||||||
if text && text != ''
|
if text && text != ''
|
||||||
|
begin
|
||||||
date = DateTime.parse(text)
|
date = DateTime.parse(text)
|
||||||
gotdate = true
|
gotdate = true
|
||||||
|
rescue
|
||||||
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue