aboutsummaryrefslogtreecommitdiff
path: root/src/Text
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2013-12-01 08:27:44 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2013-12-01 08:27:44 -0800
commitc3ac04f74fcbf960e34e8c00bab66f4d574dad71 (patch)
treedc8567a6d118d4f198a9fe7dd71a7fe635853dcc /src/Text
parent2461f244e34022e6eb23cc0261b1692e53afc987 (diff)
parent82813b55852c99c2e4d179083c119937c39d5398 (diff)
downloadpandoc-c3ac04f74fcbf960e34e8c00bab66f4d574dad71.tar.gz
Merge pull request #1074 from heurist/normalizeDateYearOnly
normalizeDate: Allow dates with year only (%Y)
Diffstat (limited to 'src/Text')
-rw-r--r--src/Text/Pandoc/Shared.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Shared.hs b/src/Text/Pandoc/Shared.hs
index 8dcd88148..7592b7659 100644
--- a/src/Text/Pandoc/Shared.hs
+++ b/src/Text/Pandoc/Shared.hs
@@ -270,7 +270,7 @@ normalizeDate s = fmap (formatTime defaultTimeLocale "%F")
(msum $ map (\fs -> parsetimeWith fs s) formats :: Maybe Day)
where parsetimeWith = parseTime defaultTimeLocale
formats = ["%x","%m/%d/%Y", "%D","%F", "%d %b %Y",
- "%d %B %Y", "%b. %d, %Y", "%B %d, %Y"]
+ "%d %B %Y", "%b. %d, %Y", "%B %d, %Y", "%Y"]
--
-- Pandoc block and inline list processing