Source/destination types
publicclassFoo{publicList<int>fooList=null;}publicclassFooDB{publicICollection<int>fooList=null;}Mapping configuration
publicclassExplicitGlobalDefaultProfile:Profile{publicExplicitGlobalDefaultProfile(){AllowNullCollections=false;AllowNullDestinationValues=true;CreateMap<Foo,FooDB>();}}publicclassImplicitGlobalDefaultProfile:Profile{publicImplicitGlobalDefaultProfile(){CreateMap<Foo,FooDB>();}}Version: x.y.z
6.1.0
Expected behavior
I expect fooDB.fooList to be an empty collection of some kind.
In 6.0.2 (and 5.2.0) this is the actual behaviour.
Actual behavior
fooList is null.
Steps to reproduce
varexplicitGlobalConfig=newMapperConfiguration(cfg =>{cfg.AddProfile<ExplicitGlobalDefaultProfile>();});varimplicitGlobalConfig=newMapperConfiguration(cfg =>{cfg.AddProfile<ImplicitGlobalDefaultProfile>();});varexplicitMapper=explicitGlobalConfig.CreateMapper();varimplicitMapper=implicitGlobalConfig.CreateMapper();varfoo=newFoo();varexplicitFooDB=explicitMapper.Map<Foo,FooDB>(foo);varimplicitFooDB=implicitMapper.Map<Foo,FooDB>(foo);
Source/destination types
Mapping configuration
Version: x.y.z
6.1.0
Expected behavior
I expect fooDB.fooList to be an empty collection of some kind.
In 6.0.2 (and 5.2.0) this is the actual behaviour.
Actual behavior
fooList is null.
Steps to reproduce