Skip to content

Support ISO8601 with hours timeshift only#2421

Merged
hueniverse merged 1 commit intohapijs:masterfrom
mzl-md:master
Aug 5, 2020
Merged

Support ISO8601 with hours timeshift only#2421
hueniverse merged 1 commit intohapijs:masterfrom
mzl-md:master

Conversation

@mzl-md
Copy link
Contributor

@mzl-md mzl-md commented Jul 28, 2020

Fix for #2419

@hueniverse hueniverse merged commit 4cb24b4 into hapijs:master Aug 5, 2020
@hueniverse hueniverse self-assigned this Aug 5, 2020
@hueniverse hueniverse added the bug Bug or defect label Aug 5, 2020
@hueniverse hueniverse added this to the 17.2.0 milestone Aug 5, 2020
hueniverse added a commit that referenced this pull request Aug 5, 2020
Copy link
Contributor

@kanongil kanongil left a comment

Choose a reason for hiding this comment

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

I forgot to submit these. It is still relevant, and as the code will bug in Safari.


// add missing trailing zeros to timeshift
if (/.*T.*[+-]\d\d$/.test(value)) {
value += '00';
Copy link
Contributor

Choose a reason for hiding this comment

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

You need to add the : as well to make it a proper extended iso date string. As it is, it breaks in Safari.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This PR is already closed and merged into the master and published in v17.2.0.
I think this issue has to become a new ticket now.

}

// add missing trailing zeros to timeshift
if (/.*T.*[+-]\d\d$/.test(value)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

The initial .* is redundant.

@hueniverse hueniverse mentioned this pull request Aug 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Bug or defect

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants