This commit is contained in:
Jannis Rieger 2024-11-14 17:50:31 +08:00 committed by GitHub
commit 5afc46e8d0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -76,7 +76,7 @@ func (db *DB) Save(value interface{}) (tx *DB) {
tx.Statement.Dest = value tx.Statement.Dest = value
reflectValue := reflect.Indirect(reflect.ValueOf(value)) reflectValue := reflect.Indirect(reflect.ValueOf(value))
for reflectValue.Kind() == reflect.Ptr || reflectValue.Kind() == reflect.Interface { for reflectValue.Kind() == reflect.Ptr {
reflectValue = reflect.Indirect(reflectValue) reflectValue = reflect.Indirect(reflectValue)
} }