Skip to content
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

EuiSuperDatePicker - safely handle negative relative times #1537

Merged
merged 3 commits into from
Feb 6, 2019

Conversation

nreese
Copy link
Contributor

@nreese nreese commented Feb 6, 2019

fixes #1536

Negative relative dates caused dateMath.parse to return undefined. This PR protects against undefined results from dateMath.parse

The PR also updates relative panel to not call the callback for negative values and instead display a validation error in the panel

screen shot 2019-02-06 at 2 22 37 pm

@nreese
Copy link
Contributor Author

nreese commented Feb 6, 2019

@snide This fix will need to go into Kibana 6.7 and 7.0. Will it have to go into a patch release for those versions?

@nreese nreese changed the title EuiSuperDatePicker - safetly handle negative relative times EuiSuperDatePicker - safely handle negative relative times Feb 6, 2019
@snide
Copy link
Contributor

snide commented Feb 6, 2019

@nreese We'll have to create a backport, or with the release so small at the moment, we may want to just ship a full update. I think only the slider is in.

Copy link
Contributor

@cchaos cchaos left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

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

change LGTM

@nreese nreese merged commit 653a660 into elastic:master Feb 6, 2019
Shigawire pushed a commit to Shigawire/eui that referenced this pull request May 10, 2019
)

* EuiSuperDatePicker - safetly handle negative relative times

* changelog

* protect against undefined returns for other calls to dateMath.parse
Sign up for free to 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.

Timepicker crashes with cannot read property 'isAfter' when the user tries to set the time
4 participants