Browse Source

in progress

0x4a52466c696e74 2 months ago
parent
commit
de0b816268
1 changed files with 1 additions and 1 deletions
  1. 1 1
      serialize.go

+ 1 - 1
serialize.go

@@ -75,7 +75,7 @@ func parseType(from, to reflect.Value, fieldName string) IErrorArgs {
 func realValue(val reflect.Value) reflect.Value {
 	if val.Kind() == reflect.Ptr || val.Kind() == reflect.Interface {
 		//if val.Kind() == reflect.Interface {
-		if val.IsNil() && val.Kind() == reflect.Ptr && val.CanSet() {
+		if val.IsNil() && val.Kind() == reflect.Ptr {
 			val.Set(reflect.New(val.Type().Elem()))
 		}
 		// check