AutoMapper / AutoMapper.Collection

AutoMapper support for updating existing collections by equivalency
MIT License
245 stars 59 forks source link

EqualityComparison not inherited when using IncludeBase #139

Closed penfold closed 1 year ago

penfold commented 4 years ago

I'm using IncludeBase to include a base mapping that contains the EqualityComparision expression.

The PKs exist in the base classes.

AM doesn't seem to be using this EqualityComparision expression when mapping collections of parent object mappings.

Should the mappings inherit EqualityComparision expressions from the base mappings?

Tasteful commented 4 years ago

As it is built it will only use equality comparison type itself, not from the base type even that IncludeBase is used.

Not sure if it is possible to be notified in AM when the IncludeBase is invoked to setup correct equality expressions there also.