Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Comparing objects of different types not working #14

Open
sekulicb opened this issue Oct 1, 2020 · 0 comments
Open

Comparing objects of different types not working #14

sekulicb opened this issue Oct 1, 2020 · 0 comments

Comments

@sekulicb
Copy link

sekulicb commented Oct 1, 2020

Hi, let's say I have an object of type Person that is base object and has two child types: Employee and Candidate. Now when comparing Employee to Candidate type I use following overload of Diff method:

var changes = source.Diff(destination, ComparionOptions.AllowCompareDifferentObjects, IgnoreProperties.ConfigureForSimpleTypes()); ( where IgnoreProperties is just a static helper class that returns an array of properties to ignore)

I can clearly see that source.FirstName and destination.FirstName are not equal, yet changes are empty every time. Both objects inherit common properties from Person. They have their own specific properties, but that was something I didn't tested. Any thought on this?

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant