Skip to content

Commit e785bc8

Browse files
committed
make time component plural
1 parent b0dbf57 commit e785bc8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Data/Formatter/DateTime.purs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,7 @@ unformatAccumToDateTime a = applySecond (validAccum a) $
258258
validAccum :: UnformatAccum Either String Unit
259259
validAccum { hour, minute, second, millisecond } = case hour of
260260
Just 24 → for_ [minute, second, millisecond] \val ->
261-
when (fromMaybe 0 val > 0) $ Left "When hour is 24, other time component must be 0"
261+
when (fromMaybe 0 val > 0) $ Left "When hour is 24, other time components must be 0"
262262
_ -> pure unit
263263

264264
adjustDay Maybe Int Int Int

test/src/DateTime.purs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ datetimeTest = describe "Data.Formatter.DateTime" do
5252

5353
describe "hour 24" do
5454
it "24 hour and more then 0 time component" $ do
55-
let err = (Left "When hour is 24, other time component must be 0@1:24")
55+
let err = (Left "When hour is 24, other time components must be 0@1:24")
5656
shouldEqual (FDT.unformatDateTime "YYYY-DD-MM HH:mm:ss:SSS" "0000-01-01 24:00:00:001") err
5757
shouldEqual (FDT.unformatDateTime "YYYY-DD-MM HH:mm:ss:SSS" "0000-01-01 24:00:01:000") err
5858
shouldEqual (FDT.unformatDateTime "YYYY-DD-MM HH:mm:ss:SSS" "0000-01-01 24:01:00:000") err

0 commit comments

Comments
 (0)