Skip to content

add default to map filter#1018

Merged
davidism merged 1 commit intopallets:masterfrom
kbiggers:jinja/557
Jul 22, 2019
Merged

add default to map filter#1018
davidism merged 1 commit intopallets:masterfrom
kbiggers:jinja/557

Conversation

@kbiggers
Copy link
Copy Markdown
Contributor

@kbiggers kbiggers commented Jun 10, 2019

added ability to pass default entry to map filter if attribute is not defined. If default is not defined it defaults to an empty string.

fixes #557

@davidism davidism changed the title Jinja/557 add default to map filter Jun 11, 2019
Copy link
Copy Markdown
Member

@davidism davidism left a comment

Choose a reason for hiding this comment

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

See comments, and needs tests as well.

Comment thread jinja2/filters.py Outdated
Comment thread jinja2/filters.py Outdated
Copy link
Copy Markdown
Contributor Author

@kbiggers kbiggers left a comment

Choose a reason for hiding this comment

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

See changes in my most recent commit. Changes should be addressed.

@kevin-brown kevin-brown requested a review from davidism June 25, 2019 00:41
Comment thread jinja2/filters.py Outdated
Comment thread jinja2/filters.py Outdated
@davidism
Copy link
Copy Markdown
Member

Sorry, noticed a couple more review items, looks good overall.

@davidism davidism added this to the 2.11.0 milestone Jul 22, 2019
@davidism davidism merged commit 52c45df into pallets:master Jul 22, 2019
@davidism
Copy link
Copy Markdown
Member

davidism commented Jul 22, 2019

OK, I merged this then noticed #985, which came a month before this and looks incredibly similar. Did I miss something where this was a continuation of that?

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add default to map filter if attribute is not defined

2 participants