
4 Jan
2020
4 Jan
'20
10:01 a.m.
On Sat, Jan 04, 2020 at 08:28:50PM +0530, Debasish Ghosh wrote:
validateOpenDate :: ZonedTime -> Validation [String] ZonedTime
It's supposed to validate a date for which I need to fetch the current date and time. I can do that with getZonedTime :: IO ZonedTime. I want to check if the current time is less than the date time I pass to the function and return an appropriate Validation.
How about validateNow = do zonedTime <- getZonedTime return (validateOpenDate zonedTime)