Closed h1048576 closed 6 years ago
err := c.Find(query).All(&d)
when d is a struct, and he has a field is struct array, unmarsh d is null
for example: type DS struct { A int bson:"a" B int bson:"c" C []CS bson:"c" }
bson:"a"
bson:"c"
type CS struct { X int bson:"x" Y int bson:"y" }
bson:"x"
bson:"y"
C is []
err := c.Find(query).All(&d)
when d is a struct, and he has a field is struct array, unmarsh d is null
for example: type DS struct { A int
bson:"a"
B intbson:"c"
C []CSbson:"c"
}type CS struct { X int
bson:"x"
Y intbson:"y"
}C is []