Closed Bug 977097 Opened 10 years ago Closed 10 years ago

Add more aliases for the UTC timezone

Categories

(Calendar :: Internal Components, defect)

Lightning 2.6
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: Fallen, Assigned: Fallen)

Details

Attachments

(1 file)

Attached patch utcaliases.diff β€” β€” Splinter Review
I've run into the situation where other clients will send an event with TZID=Etc/GMT without defining the timezone. To work around this I think we can add a few more aliases (taken from wikipedia) for UTC.

I will need this for 2.6.5, given I am just adding functionality and not changing it I think the risk is low enough.
Attachment #8382218 - Flags: review?(mohit.kanwal)
Attachment #8382218 - Flags: approval-calendar-release+
Attachment #8382218 - Flags: approval-calendar-beta+
Attachment #8382218 - Flags: approval-calendar-aurora+
Comment on attachment 8382218 [details] [diff] [review]
utcaliases.diff

Review of attachment 8382218 [details] [diff] [review]:
-----------------------------------------------------------------

::: calendar/base/src/calTimezoneService.js
@@ +102,5 @@
> +                                "Etc/UCT", "Etc/Unversal", "Etc/UTC",
> +                                "Etc/Zulu", "GMT", "GMT+0", "GMT0",
> +                                "Greenwich", "UCT", "Universal", "Zulu"];
> +
> +            for (let zone of utcAliases) {

shouldn't this be let zone in utcAliases?
Attachment #8382218 - Flags: review?(mohit.kanwal) → review-
Comment on attachment 8382218 [details] [diff] [review]
utcaliases.diff

Its new and shiny :)

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for...of

the old method was for each (let zone in utcAliases), the new one is for (let zone of utcAliases).
Attachment #8382218 - Flags: review- → review?(mohit.kanwal)
Comment on attachment 8382218 [details] [diff] [review]
utcaliases.diff

Review of attachment 8382218 [details] [diff] [review]:
-----------------------------------------------------------------

Ah! I missed that. Looks pretty shiny :) although to me for each..in still makes readable sense :)

::: calendar/base/src/calTimezoneService.js
@@ +102,5 @@
> +                                "Etc/UCT", "Etc/Unversal", "Etc/UTC",
> +                                "Etc/Zulu", "GMT", "GMT+0", "GMT0",
> +                                "Greenwich", "UCT", "Universal", "Zulu"];
> +
> +            for (let zone of utcAliases) {

Ha Ha! Learnt something new! Nice!
Attachment #8382218 - Flags: review?(mohit.kanwal) → review+
Pushed to comm-central changeset 75415ebea93e
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → 3.2
Backported to releases/comm-aurora changeset 24ae86940cfe
Target Milestone: 3.2 → 3.1
Backported to releases/comm-beta changeset 1643851618ef
Target Milestone: 3.1 → 3.0
Backported to releases/comm-esr24 changeset 23aabf445f76
Target Milestone: 3.0 → 2.6.5
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: