na1s
na1s

Reputation: 177

Mongodb C# driver with ignoreNull and ignore bool default values

It is impossible to set ignoreNull and ignoreDefault together. Is it possible to set ignore all nulls and boolean false values?

Upvotes: 0

Views: 2057

Answers (1)

Craig Wilson
Craig Wilson

Reputation: 12624

No, these are mutually exclusive. You shouldn't need to set both of these at the same time as a property will only have 1 default value. For reference types, it's null and for value types its a value (bool, for instance, is false). You should be able to set IgnoreIfDefault and be fine.

Upvotes: 3

Related Questions