Use ParseDate in Parse

Also limit to English, or we get lots of false positives
This commit is contained in:
Dan Jones 2024-02-25 13:12:13 -06:00
commit 96c3b2ff30
3 changed files with 7 additions and 4 deletions

View file

@ -26,6 +26,7 @@ func ParseDate(in string) (t time.Time, err error) {
conf := dp.Configuration{
CurrentTime: time.Now().Local(),
ReturnTimeAsPeriod: true,
Languages: []string{"en"},
}
d, err := dp.Parse(&conf, in)