A convention that sets whether to ignore nulls during serialization.
Inheritance: ConventionBase, IMemberMapConvention
        public void TestApply(bool value)
        {
            var subject = new IgnoreIfNullConvention(value);
            var classMap = new BsonClassMap<TestClass>();
            var memberMap = classMap.MapMember(x => x.Id);

            subject.Apply(memberMap);

            Assert.AreEqual(value, memberMap.IgnoreIfNull);
        }
        static AbstractRepository()
        {
            var pack = new ConventionPack();
            var ignoreIfNull = new IgnoreIfNullConvention(true);
            pack.Add(ignoreIfNull);
            ConventionRegistry.Register("ignoreNulls", pack, t => true);

            Migrations.CreatePointsOfInterest();
            Migrations.CreateUsers();
            Migrations.EnsureGeospacialIndex();
            Migrations.EnsureUniqueEmailIndex();
            Migrations.CreateLocationTypes();
        }