Compare commits
2 Commits
09c64ba254
...
6c6e467e3a
| Author | SHA1 | Date | |
|---|---|---|---|
| 6c6e467e3a | |||
| ba21b39c41 |
@@ -106,3 +106,11 @@ func (t *Time) getTimeFormat(defaultFormat string, layout ...string) string {
|
||||
}
|
||||
return defaultFormat
|
||||
}
|
||||
|
||||
func DefaultZeroTime() time.Time {
|
||||
return time.Date(1970, 1, 1, 0, 0, 0, 0, time.Local)
|
||||
}
|
||||
|
||||
func IsZeroTime(t time.Time) bool {
|
||||
return t.IsZero() || t.Year() == 1970
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user