File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ func updateTimeStampForCreateCallback(scope *Scope) {
50
50
// createCallback the callback used to insert data into database
51
51
func createCallback (scope * Scope ) {
52
52
if ! scope .HasError () {
53
- defer scope .trace (scope . db . nowFunc ())
53
+ defer scope .trace (NowFunc ())
54
54
55
55
var (
56
56
columns , placeholders []string
Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ func queryCallback(scope *Scope) {
24
24
return
25
25
}
26
26
27
- defer scope .trace (scope . db . nowFunc ())
27
+ defer scope .trace (NowFunc ())
28
28
29
29
var (
30
30
isSlice , isPtr bool
Original file line number Diff line number Diff line change @@ -358,7 +358,7 @@ func (scope *Scope) Raw(sql string) *Scope {
358
358
359
359
// Exec perform generated SQL
360
360
func (scope * Scope ) Exec () * Scope {
361
- defer scope .trace (scope . db . nowFunc ())
361
+ defer scope .trace (NowFunc ())
362
362
363
363
if ! scope .HasError () {
364
364
if result , err := scope .SQLDB ().Exec (scope .SQL , scope .SQLVars ... ); scope .Err (err ) == nil {
@@ -934,7 +934,7 @@ func (scope *Scope) updatedAttrsWithValues(value interface{}) (results map[strin
934
934
}
935
935
936
936
func (scope * Scope ) row () * sql.Row {
937
- defer scope .trace (scope . db . nowFunc ())
937
+ defer scope .trace (NowFunc ())
938
938
939
939
result := & RowQueryResult {}
940
940
scope .InstanceSet ("row_query_result" , result )
@@ -944,7 +944,7 @@ func (scope *Scope) row() *sql.Row {
944
944
}
945
945
946
946
func (scope * Scope ) rows () (* sql.Rows , error ) {
947
- defer scope .trace (scope . db . nowFunc ())
947
+ defer scope .trace (NowFunc ())
948
948
949
949
result := & RowsQueryResult {}
950
950
scope .InstanceSet ("row_query_result" , result )
You can’t perform that action at this time.
0 commit comments