-
Notifications
You must be signed in to change notification settings - Fork 332
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
Invalid mapping to exists class if source is object #524
Comments
Possibly related to #485 |
not fix - collection issue MapsterMapper#430 MapsterMapper#546 - object to ToDistination MapsterMapper#524
Typeof(TSource) always return Type as Object. Need use dynamic or Cast to Runtime Type before Adapt What happens is this: In this case use special overload from (it work) :
But a new instance is when the TDistination is detection as Record #537 |
I get fix it, but this |
This Adapt Source from object to type of TDestination == ObjectAdapter not created Update function |
Thank you @DocSvartz, I will review it later today! :) |
result:
123 123 19575591 19575591
, dest and dest1 are the same objectresult:
321 123 32001227 19575591
dest not changed, dest1 is a new object.
Any ideas? Why if source is object, Adapt create a new instance of dest class?
The text was updated successfully, but these errors were encountered: