Skip to content

add warnings when datetime-related filters called with null arguments - #1064

Merged
boulter merged 2 commits into
masterfrom
jboulter-add-warnings-when-datetimefilters-called-with-null-arguments
May 1, 2023
Merged

add warnings when datetime-related filters called with null arguments#1064
boulter merged 2 commits into
masterfrom
jboulter-add-warnings-when-datetimefilters-called-with-null-arguments

Conversation

@boulter

Copy link
Copy Markdown
Contributor

In the future we may change this behavior so null args do not default to the current time. I suspect many users didn't know this was happening since there was no warning.

@boulter
boulter requested review from jasmith-hs and tkindyMay 1, 2023 19:45

@Before
public void setup() {
jinjava.getGlobalContext().registerClasses(EscapeJsFilter.class);

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

seems like this was copied from some other test

@jasmith-hsjasmith-hs left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Want to add a test that the warning gets added?

@boulter

Copy link
Copy Markdown
ContributorAuthor

Want to add a test that the warning gets added?

Oh weird, I had one. Where did it go?

@boulter

Copy link
Copy Markdown
ContributorAuthor

Here it is https://github.com/HubSpot/jinjava/pull/1064/files#diff-2740cb9df07e1f33ad3d52accf29288495951cbbdecc47da93e6aec69f47ec22R36

@jasmith-hs

Copy link
Copy Markdown
Contributor

@boulter
boulter merged commit 055f189 into masterMay 1, 2023
@boulter
boulter deleted the jboulter-add-warnings-when-datetimefilters-called-with-null-arguments branch May 1, 2023 21:12
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@boulter@jasmith-hs@jboulter