Giter Site home page Giter Site logo

Comments (10)

TylerCarlson1 avatar TylerCarlson1 commented on June 25, 2024 1

2.1.0 Should fix this issue.

Removed as much of AutoMapper's internal code I was using before, so hopefully only refactors of the API will only require updates.

from automapper.collection.

TylerCarlson1 avatar TylerCarlson1 commented on June 25, 2024 1

2.1.1 should fix the original issue. Wrote unit tests for it.

from automapper.collection.

TylerCarlson1 avatar TylerCarlson1 commented on June 25, 2024

I think this is a bug with AutoMapper 5.0.2 and you need to upgrade that. When source or destination are null it defaults back to the CollectionMapper in AutoMapper to do the mapping.

I know Collection mapping has been updated recently in AutoMapper.

from automapper.collection.

dmdymov avatar dmdymov commented on June 25, 2024

For the latest AutoMapper 5.1.1:

System.MethodAccessException at Mapper.Initialize:
"AutoMapper.Mappers.EquivlentExpressionAddRemoveCollectionMapper.IsMatch(AutoMapper.TypePair)" couldn't get access to "AutoMapper.Configuration.PrimitiveExtensions.IsEnumerableType(System.Type)"

Any thoughts on this?

from automapper.collection.

TylerCarlson1 avatar TylerCarlson1 commented on June 25, 2024

Now THAT is a bug that I need to fix.

I'll try to make a build that fixes it that works in 5.1.1 by the end of the week.

from automapper.collection.

dmdymov avatar dmdymov commented on June 25, 2024

Yes, there's no exception with 2.1.0. But null as a result of mapping is still there. I think I'll try to create an Automapper issue.

from automapper.collection.

dmdymov avatar dmdymov commented on June 25, 2024

I am here again. AutoMapper issue.

@lbargaoanu :

Then I guess @TylerCarlson1 should help you here.

What should I do know? This is getting a bit weird.

from automapper.collection.

TylerCarlson1 avatar TylerCarlson1 commented on June 25, 2024

I'll have to look into it some more then.

from automapper.collection.

TylerCarlson1 avatar TylerCarlson1 commented on June 25, 2024

Yea when updating the logic changed and the null check changed and caused the functionality to break for nulls.

from automapper.collection.

dmdymov avatar dmdymov commented on June 25, 2024

Everything is OK now, thank you.

from automapper.collection.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.