allow trailing Z on iso 8601 parsing
This commit is contained in:
parent
2d42bbf464
commit
67b24641e2
|
@ -147,6 +147,8 @@ pub fn parseIso8601ToDateTime(data: []const u8) !DateTime {
|
||||||
// Basic format YYYYMMDDThhmmss
|
// Basic format YYYYMMDDThhmmss
|
||||||
if (data.len == "YYYYMMDDThhmmss".len and data[8] == 'T')
|
if (data.len == "YYYYMMDDThhmmss".len and data[8] == 'T')
|
||||||
return try parseIso8601BasicFormatToDateTime(data);
|
return try parseIso8601BasicFormatToDateTime(data);
|
||||||
|
if (data.len == "YYYYMMDDThhmmssZ".len and data[8] == 'T')
|
||||||
|
return try parseIso8601BasicFormatToDateTime(data);
|
||||||
|
|
||||||
var start: usize = 0;
|
var start: usize = 0;
|
||||||
var state = IsoParsingState.Start;
|
var state = IsoParsingState.Start;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user