UX: Ensures timezone is used over localTimezone when displaying dates

This commit is contained in:
Joffrey JAFFEUX 2020-04-08 11:43:47 +02:00 committed by GitHub
parent 94c0228681
commit 6d0ba74b98
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -32,7 +32,7 @@ export default class LocalDateBuilder {
displayedTimezone = this.displayedTimezone || this.localTimezone;
} else {
displayedTimezone =
this.displayedTimezone || this.localTimezone || this.timezone;
this.displayedTimezone || this.timezone || this.localTimezone;
}
let localDate = new DateWithZoneHelper({

View File

@ -81,7 +81,7 @@ QUnit.test("option[format]", assert => {
freezeTime({ date: "2020-03-11" }, () => {
assert.buildsCorrectDate(
{ format: "YYYY" },
{ formated: "2020" },
{ formated: "2020 (UTC)" },
"it uses custom format"
);
});