Skip to content

Trim keys when mapping from dictionaries#3487

Merged
jbogard merged 4 commits intoLuckyPennySoftware:masterfrom
dim5:trim-dict-key
Aug 26, 2020
Merged

Trim keys when mapping from dictionaries#3487
jbogard merged 4 commits intoLuckyPennySoftware:masterfrom
dim5:trim-dict-key

Conversation

@dim5
Copy link
Copy Markdown
Contributor

@dim5 dim5 commented Aug 23, 2020

  • Now when mapping from string dictionaries keys surrounded with white-spaces are considered
    • Preferring the one with the least amount of white-spaces, when multiple entries are present
  • Added matching tests

Fixes #3483

dim5 added 2 commits August 23, 2020 23:37
it now matches keys w/ whitespaces, preferring ones without any
@dnfadmin
Copy link
Copy Markdown

dnfadmin commented Aug 23, 2020

CLA assistant check
All CLA requirements met.

Comment thread src/AutoMapper/Mappers/FromStringDictionaryMapper.cs
@lbargaoanu lbargaoanu changed the title Trim dict key Trim keys when mapping from dictionaries Aug 24, 2020
Comment thread src/AutoMapper/Mappers/FromStringDictionaryMapper.cs Outdated
Copy link
Copy Markdown
Contributor

@lbargaoanu lbargaoanu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@lbargaoanu
Copy link
Copy Markdown
Contributor

@jbogard I think merge this one so I can rebase my PR.

@jbogard jbogard merged commit eafff20 into LuckyPennySoftware:master Aug 26, 2020
@lbargaoanu lbargaoanu added this to the v.next milestone Sep 15, 2020
@github-actions
Copy link
Copy Markdown

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Consider trimming keys when mapping from dictionaries

4 participants