Both -00:30 and +00:30 results in the same offset (0, 30)
jinjor opened this issue · comments
Yosuke Torii commented
SSCCE
$ elm repl
---- Elm 0.19.0 ----------------------------------------------------------------
Read <https://elm-lang.org/0.19.0/repl> to learn more: exit, help, imports, etc.
--------------------------------------------------------------------------------
> import ISO8601
> ISO8601.fromString "2019-09-12T12:00+00:30"
Ok { day = 12, hour = 12, millisecond = 0, minute = 0, month = 9, offset = (0,30), second = 0, year = 2019 }
: Result String ISO8601.Time
> ISO8601.fromString "2019-09-12T12:00-00:30"
Ok { day = 12, hour = 12, millisecond = 0, minute = 0, month = 9, offset = (0,30), second = 0, year = 2019 }
: Result String ISO8601.Time
Possible Solution
Use offset : Int
(minutes) instead of offset : (Int, Int)
(hours, minutes).
Yosuke Torii commented
Turned out that there is no such timezone, so I believe this is practically safe!
John Weir commented
Thanks for the bug report! A new version has been pushed up.