Time fix.

This commit is contained in:
Nuno Cruces
2024-10-04 16:39:34 +01:00
parent 96c61a2f55
commit f9e867be60
4 changed files with 10 additions and 3 deletions

View File

@@ -138,6 +138,9 @@ func (f TimeFormat) Encode(t time.Time) any {
//
// https://sqlite.org/lang_datefunc.html
func (f TimeFormat) Decode(v any) (time.Time, error) {
if t, ok := v.(time.Time); ok {
return t, nil
}
switch f {
// Numeric formats.
case TimeFormatJulianDay: