Skip to content

Commit 75ee151

Browse files
GODRIVER-3470 Clean up comment
1 parent 32190fe commit 75ee151

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

bson/bsoncodec/default_value_decoders.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1570,11 +1570,11 @@ func (dvd DefaultValueDecoders) UnmarshalerDecodeValue(_ DecodeContext, vr bsonr
15701570
}
15711571

15721572
// If BSON value is null and the go value is a pointer, then don't call
1573-
// UnmarshalBSONValue. Even if the Go pointer is already initialized (i.e.,
1573+
// UnmarshalBSON. Even if the Go pointer is already initialized (i.e.,
15741574
// non-nil), encountering null in BSON will result in the pointer being
15751575
// directly set to nil here. Since the pointer is being replaced with nil,
1576-
// there is no opportunity (or reason) for the custom UnmarshalBSONValue logic
1577-
// to be called.
1576+
// there is no opportunity (or reason) for the custom UnmarshalBSON logic to
1577+
// be called.
15781578
if val.Kind() == reflect.Ptr && vr.Type() == bsontype.Null {
15791579
val.Set(reflect.Zero(val.Type()))
15801580

0 commit comments

Comments
 (0)