mirror of
https://github.com/gohugoio/hugo.git
synced 2024-12-24 16:31:15 +00:00
Support ISO8601 date/time format without timezones
This commit is contained in:
parent
0bfe9276c2
commit
e4af4f652e
1 changed files with 1 additions and 0 deletions
|
@ -38,6 +38,7 @@ func interfaceToStringToDate(i interface{}) time.Time {
|
||||||
func stringToDate(s string) (time.Time, error) {
|
func stringToDate(s string) (time.Time, error) {
|
||||||
return parseDateWith(s, []string{
|
return parseDateWith(s, []string{
|
||||||
time.RFC3339,
|
time.RFC3339,
|
||||||
|
"2006-01-02T15:04:05", // iso8601 without timezone
|
||||||
time.RFC1123Z,
|
time.RFC1123Z,
|
||||||
time.RFC1123,
|
time.RFC1123,
|
||||||
time.RFC822Z,
|
time.RFC822Z,
|
||||||
|
|
Loading…
Reference in a new issue