diff options
author | Joris | 2015-10-10 11:22:03 +0200 |
---|---|---|
committer | Joris | 2015-10-10 11:22:03 +0200 |
commit | 7825b27d262af7252b48e9179a5bbf86b0f30d22 (patch) | |
tree | 2d85883a427fa1183cd5f7737b58e29ba2471828 /src/Date.hs | |
parent | dd16fd43b09a881a43433174728cf45792cce8ae (diff) |
More readable birthdates in csv file
Diffstat (limited to 'src/Date.hs')
-rw-r--r-- | src/Date.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Date.hs b/src/Date.hs index efbef8c..07f0672 100644 --- a/src/Date.hs +++ b/src/Date.hs @@ -20,8 +20,8 @@ getCurrentDate = do now <- getCurrentTime timezone <- getCurrentTimeZone let zoneNow = utcToLocalTime timezone now - let (year, month, day) = toGregorian $ localDay zoneNow - return $ Date (fromIntegral year) month day + let (y, m, d) = toGregorian $ localDay zoneNow + return $ Date (fromIntegral y) m d sameDayAndMonth :: Date -> Date -> Bool sameDayAndMonth (Date _ m1 d1) (Date _ m2 d2) = m1 == m2 && d1 == d2 |