Use ISO 8601 date format (yyyy-mm-dd)

This commit is contained in:
Simon Legner 2018-05-04 12:36:14 +02:00
parent 5307e97d66
commit e6dae03329

View File

@ -398,10 +398,10 @@ outer:
return nil
}
// Formats a unix timestamp to yyyy/mm/dd
// Formats a unix timestamp to ISO 8601 date (yyyy-mm-dd)
func formatTime(i int) string {
t := time.Unix(int64(i), 0)
return fmt.Sprintf("%d/%02d/%02d", t.Year(), int(t.Month()), t.Day())
return t.Format("2006-01-02")
}
const (