Make iso8601_to_datetime a bit more compliant
|Reported by:||chrisscott||Owned by:|
With a valid ISO 8601 date string with dashes in the date or decimal fractions for seconds, this function will fail to parse it correctly. The attached patch updates the regex to optionally accept dashes and decimal fractions for seconds (which are ignored). It also uses a variable for the regex since it was duplicated.
Change History (7)
comment:1 solarissmoke — 3 years ago
- Component changed from General to Formatting
- Keywords has-patch added
- Keywords needs-patch 2nd-opinion added; has-patch needs-unit-tests removed