Fix linting errors

This commit is contained in:
Patrick Pacher
2024-03-27 16:17:58 +01:00
parent 653a365bce
commit 61176af14e
48 changed files with 167 additions and 153 deletions

View File

@@ -2,6 +2,7 @@ package orm
import (
"context"
"errors"
"fmt"
"reflect"
"time"
@@ -171,7 +172,7 @@ func DatetimeEncoder(loc *time.Location) EncodeFunc {
valInterface := val.Interface()
t, ok = valInterface.(time.Time)
if !ok {
return nil, false, fmt.Errorf("cannot convert reflect value to time.Time")
return nil, false, errors.New("cannot convert reflect value to time.Time")
}
case valType.Kind() == reflect.String && colDef.IsTime: