Hi,
I just saw a very strange behaviour, maybe you can explain… but it looks like a bug.
I have some very simple valueobjects as classes in my code.
Some of them can be created with a public constructor passing an IEnumerable with parameter name “items”.
For my purpose I don’t need any custom BsonClassMaps because automap works fine so far…
This does not work
public class PrNumbers : ListValueObject<PrNumbers>
{
public PrNumbers(IEnumerable<PrNumbers> items) : base(items) { }
}
MongoDB.Bson.BsonSerializationException: Creator map for class …PrNumbers has 1 arguments, but none are configured.
This does work
public class PrNumbers : ListValueObject<PrNumbers>
{
public PrNumbers(IEnumerable<PrNumbers> prnumbers) : base(prnumbers) { }
}
The only change is just the parameter name… nothing else… any idea why?
Best regards,
Simon