Skip to content

Commit e5d47a2

Browse files
committed
chore: cleanup
1 parent 6eedee3 commit e5d47a2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

decode_value.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ func ptrValueDecoder(typ reflect.Type) decoderFunc {
128128
return func(d *Decoder, v reflect.Value) error {
129129
if d.hasNilCode() {
130130
if !v.IsNil() {
131-
v.Set(reflect.Zero(v.Type()))
131+
v.Set(d.newValue(typ).Elem())
132132
}
133133
return d.DecodeNil()
134134
}

0 commit comments

Comments
 (0)