Bug 1383995 - Run eslint fix over calendar. draft
authorTom Prince <mozilla@hocat.ca>
Mon, 24 Jul 2017 23:54:22 -0600
changeset 22257 e400ff586040acb4e264fa02243a08684621fef5
parent 22256 f529d51d81172f9128280e3612c2d4a54804df43
push id93
push userbmo:mozilla@hocat.ca
push dateTue, 25 Jul 2017 05:54:34 +0000
bugs1383995
Bug 1383995 - Run eslint fix over calendar. MozReview-Commit-ID: 4Yi6mSl5ZJf
calendar/base/content/calendar-chrome-startup.js
calendar/base/content/calendar-common-sets.js
calendar/base/content/calendar-item-editing.js
calendar/base/content/calendar-management.js
calendar/base/content/calendar-task-tree.js
calendar/base/content/calendar-ui-utils.js
calendar/base/content/calendar-views.js
calendar/base/content/dialogs/calendar-event-dialog-recurrence.js
calendar/base/content/preferences/alarms.js
calendar/base/content/today-pane.js
calendar/base/modules/calAlarmUtils.jsm
calendar/base/modules/calAuthUtils.jsm
calendar/base/modules/calExtract.jsm
calendar/base/modules/calItipUtils.jsm
calendar/base/modules/calRecurrenceUtils.jsm
calendar/base/modules/calUtils.jsm
calendar/base/src/calAlarm.js
calendar/base/src/calAttendee.js
calendar/base/src/calCachedCalendar.js
calendar/base/src/calDateTimeFormatter.js
calendar/base/src/calFilter.js
calendar/base/src/calItemBase.js
calendar/base/src/calUtils.js
calendar/lightning/content/lightning-item-iframe.js
calendar/lightning/content/lightning-item-panel.js
calendar/lightning/content/messenger-overlay-sidebar.js
calendar/lightning/modules/ltnInvitationUtils.jsm
calendar/providers/caldav/calDavCalendar.js
calendar/providers/storage/calStorageCalendar.js
calendar/providers/storage/calStorageUpgrade.jsm
calendar/providers/wcap/calWcapSession.js
calendar/test/mozmill/invitations/test-imip-bar-eml.js
calendar/test/mozmill/shared-modules/test-calendar-utils.js
calendar/test/unit/head_consts.js
calendar/test/unit/test_alarmservice.js
calendar/test/unit/test_attendee.js
calendar/test/unit/test_bug1199942.js
calendar/test/unit/test_bug759324.js
calendar/test/unit/test_calitiputils.js
calendar/test/unit/test_datetimeformatter.js
calendar/test/unit/test_ltninvitationutils.js
calendar/test/unit/test_recur.js
calendar/test/unit/test_storage.js
calendar/test/unit/test_timezone.js
--- a/calendar/base/content/calendar-chrome-startup.js
+++ b/calendar/base/content/calendar-chrome-startup.js
@@ -46,21 +46,21 @@ function commonInitCalendar() {
     categoryManagement.initCategories();
 
     // Set up window pref observers
     calendarWindowPrefs.init();
 
     // Set up the available modifiers for each platform.
     let keys = document.querySelectorAll("#calendar-keys > key");
     let platform = AppConstants.platform;
-        for (let key of keys) {
-            if (key.hasAttribute("modifiers-" + platform)) {
-                key.setAttribute("modifiers", key.getAttribute("modifiers-" + platform));
-            }
+    for (let key of keys) {
+        if (key.hasAttribute("modifiers-" + platform)) {
+            key.setAttribute("modifiers", key.getAttribute("modifiers-" + platform));
         }
+    }
 
     /* Ensure the new items commands state can be setup properly even when no
      * calendar support refreshes (i.e. the "onLoad" notification) or when none
      * are active. In specific cases such as for file-based ICS calendars can
      * happen, the initial "onLoad" will already have been triggered at this
      * point (see bug 714431 comment 29). We thus inconditionnally invoke
      * calendarUpdateNewItemsCommand until somebody writes code that enables the
      * checking of the calendar readiness (getProperty("ready") ?).
--- a/calendar/base/content/calendar-common-sets.js
+++ b/calendar/base/content/calendar-common-sets.js
@@ -896,20 +896,20 @@ function deleteSelectedItems() {
 
 function calendarUpdateNewItemsCommand() {
     // keep current current status
     let oldEventValue = CalendarNewEventsCommandEnabled;
     let oldTaskValue = CalendarNewTasksCommandEnabled;
 
     // define command set to update
     let eventCommands = ["calendar_new_event_command",
-                         "calendar_new_event_context_command"];
+        "calendar_new_event_context_command"];
     let taskCommands = ["calendar_new_todo_command",
-                        "calendar_new_todo_context_command",
-                        "calendar_new_todo_todaypane_command"];
+        "calendar_new_todo_context_command",
+        "calendar_new_todo_todaypane_command"];
 
     // re-calculate command status
     CalendarNewEventsCommandEnabled = false;
     CalendarNewTasksCommandEnabled = false;
     let calendars = cal.getCalendarManager().getCalendars({}).filter(cal.isCalendarWritable).filter(cal.userCanAddItemsToCalendar);
     if (calendars.some(cal.isEventCalendar)) {
         CalendarNewEventsCommandEnabled = true;
     }
@@ -935,17 +935,17 @@ function calendarUpdateDeleteCommand(sel
         if (!cal.userCanDeleteItemsFromCalendar(item.calendar)) {
             CalendarDeleteCommandEnabled = false;
             break;
         }
     }
 
     if (CalendarDeleteCommandEnabled != oldValue) {
         let commands = ["calendar_delete_event_command",
-                        "calendar_delete_todo_command",
-                        "calendar_delete_focused_item_command",
-                        "button_delete",
-                        "cmd_delete"];
+            "calendar_delete_todo_command",
+            "calendar_delete_focused_item_command",
+            "button_delete",
+            "cmd_delete"];
         for (let command of commands) {
             goUpdateCommand(command);
         }
     }
 }
--- a/calendar/base/content/calendar-item-editing.js
+++ b/calendar/base/content/calendar-item-editing.js
@@ -326,17 +326,17 @@ function createTodoWithDialog(calendar, 
  * @param aPromptOccurrence     If the user should be prompted to select if the
  *                                parent item or occurrence should be modified.
  * @param initialDate           (optional) The initial date for new task datepickers
  * @param aCounterProposal      (optional) An object representing the counterproposal
  *        {
  *            {JsObject} result: {
  *                type: {String} "OK"|"OUTDATED"|"NOTLATESTUPDATE"|"ERROR"|"NODIFF"
  *                descr: {String} a technical description of the problem if type is ERROR or NODIFF,
- *                                otherwise an empty string 
+ *                                otherwise an empty string
  *            },
  *            (empty if result.type = "ERROR"|"NODIFF"){Array} differences: [{
  *                property: {String} a property that is subject to the proposal
  *                proposed: {String} the proposed value
  *                original: {String} the original value
  *            }]
  *        }
  */
--- a/calendar/base/content/calendar-management.js
+++ b/calendar/base/content/calendar-management.js
@@ -346,17 +346,17 @@ function showOnlyCalendar(aCalendar) {
         }
     }
     composite.addCalendar(aCalendar);
     composite.endBatch();
 }
 
 var compositeObserver = {
     QueryInterface: XPCOMUtils.generateQI([Components.interfaces.calIObserver,
-                                           Components.interfaces.calICompositeObserver]),
+        Components.interfaces.calICompositeObserver]),
 
     onStartBatch: function() {},
     onEndBatch: function() {},
     onAddItem: function() {},
     onModifyItem: function() {},
     onDeleteItem: function() {},
     onError: function() {},
     onPropertyChanged: function() {},
--- a/calendar/base/content/calendar-task-tree.js
+++ b/calendar/base/content/calendar-task-tree.js
@@ -99,20 +99,20 @@ function handleTaskContextMenuStateChang
 /**
  * Change the opening menu for the selected tasks.
  *
  * @param aEvent    The popupshowing event of the opening menu.
  */
 function changeMenuForTask(aEvent) {
     // Make sure to update the status of some commands.
     ["calendar_delete_todo_command",
-     "calendar_toggle_completed_command",
-     "calendar_general-progress_command",
-     "calendar_general-priority_command",
-     "calendar_general-postpone_command"].forEach(goUpdateCommand);
+        "calendar_toggle_completed_command",
+        "calendar_general-progress_command",
+        "calendar_general-priority_command",
+        "calendar_general-postpone_command"].forEach(goUpdateCommand);
 
     let tasks = getSelectedTasks(aEvent);
     let tasksSelected = (tasks.length > 0);
     if (tasksSelected) {
         let cmd = document.getElementById("calendar_toggle_completed_command");
         if (cal.isPropertyValueSame(tasks, "isCompleted")) {
             setBooleanAttribute(cmd, "checked", tasks[0].isCompleted);
         } else {
--- a/calendar/base/content/calendar-ui-utils.js
+++ b/calendar/base/content/calendar-ui-utils.js
@@ -553,38 +553,38 @@ function getSummarizedStyleValues(aXULEl
  * by considering the css rules for the min-width, padding, border, margin
  * and border of the box.
  *
  * @param aXULElement   The xul element to be inspected.
  * @return              An integer value denoting the optimal minimum width
  */
 function getOptimalMinimumWidth(aXULElement) {
     return getSummarizedStyleValues(aXULElement, ["min-width",
-                                                  "padding-left", "padding-right",
-                                                  "margin-left", "margin-top",
-                                                  "border-left-width", "border-right-width"]);
+        "padding-left", "padding-right",
+        "margin-left", "margin-top",
+        "border-left-width", "border-right-width"]);
 }
 
 /**
  * Calculates the optimal minimum height based on the set css style-rules
  * by considering the css rules for the font-size, padding, border, margin
  * and border of the box. In its current state the line-height is considered
  * by assuming that it's size is about one third of the size of the font-size
  *
  * @param aXULElement   The xul-element to be inspected.
  * @return              An integer value denoting the optimal minimum height
  */
 function getOptimalMinimumHeight(aXULElement) {
     // the following line of code presumes that the line-height is set to "normal"
     // which is supposed to be a "reasonable distance" between the lines
     let firstEntity = parseInt(1.35 * getSummarizedStyleValues(aXULElement, ["font-size"]), 10);
     let secondEntity = getSummarizedStyleValues(aXULElement,
-                                                ["padding-bottom", "padding-top",
-                                                "margin-bottom", "margin-top",
-                                                "border-bottom-width", "border-top-width"]);
+        ["padding-bottom", "padding-top",
+            "margin-bottom", "margin-top",
+            "border-bottom-width", "border-top-width"]);
     return (firstEntity + secondEntity);
 }
 
 /**
  * Gets the "other" orientation value, i.e if "horizontal" is passed, "vertical"
  * is returned and vice versa.
  *
  * @param aOrientation    The orientation value to turn around.
--- a/calendar/base/content/calendar-views.js
+++ b/calendar/base/content/calendar-views.js
@@ -209,29 +209,29 @@ function switchToView(aViewType) {
             } else {
                 node.setAttribute(attr, node.getAttribute(attr + "-all"));
             }
         }
     }
 
     // Set up the labels and accesskeys for the context menu
     ["calendar-view-context-menu-next",
-     "calendar-view-context-menu-previous",
-     "calendar-go-menu-next",
-     "calendar-go-menu-previous",
-     "appmenu_calendar-go-menu-next",
-     "appmenu_calendar-go-menu-previous"].forEach((x) => {
-         setupViewNode(x, "label");
-         setupViewNode(x, "accesskey");
-     });
+        "calendar-view-context-menu-previous",
+        "calendar-go-menu-next",
+        "calendar-go-menu-previous",
+        "appmenu_calendar-go-menu-next",
+        "appmenu_calendar-go-menu-previous"].forEach((x) => {
+            setupViewNode(x, "label");
+            setupViewNode(x, "accesskey");
+        });
 
     // Set up the labels for the view navigation
     ["previous-view-button",
-     "today-view-button",
-     "next-view-button"].forEach(x => setupViewNode(x, "tooltiptext"));
+        "today-view-button",
+        "next-view-button"].forEach(x => setupViewNode(x, "tooltiptext"));
 
     try {
         selectedDay = viewDeck.selectedPanel.selectedDay;
         currentSelection = viewDeck.selectedPanel.getSelectedItems({});
     } catch (ex) {
         // This dies if no view has even been chosen this session, but that's
         // ok because we'll just use cal.now() below.
     }
--- a/calendar/base/content/dialogs/calendar-event-dialog-recurrence.js
+++ b/calendar/base/content/dialogs/calendar-event-dialog-recurrence.js
@@ -785,20 +785,20 @@ function changeOrderForElements(aPropKey
     }
 }
 
 /**
  * Change locale-specific widget order for Edit Recurrence window
  */
 function changeWidgetsOrder() {
     changeOrderForElements("monthlyOrder",
-                           ["monthly-ordinal",
-                            "monthly-weekday"]);
+        ["monthly-ordinal",
+            "monthly-weekday"]);
     changeOrderForElements("yearlyOrder",
-                           ["yearly-days",
-                            "yearly-period-of-month-label",
-                            "yearly-month-ordinal"]);
+        ["yearly-days",
+            "yearly-period-of-month-label",
+            "yearly-month-ordinal"]);
     changeOrderForElements("yearlyOrder2",
-                           ["yearly-ordinal",
-                            "yearly-weekday",
-                            "yearly-period-of-label",
-                            "yearly-month-rule"]);
+        ["yearly-ordinal",
+            "yearly-weekday",
+            "yearly-period-of-label",
+            "yearly-month-rule"]);
 }
--- a/calendar/base/content/preferences/alarms.js
+++ b/calendar/base/content/preferences/alarms.js
@@ -121,17 +121,17 @@ var gAlarmsPane = {
      * has been changed. Updates the disabled state of fields that depend on
      * playing a sound.
      */
     alarmsPlaySoundPrefChanged: function() {
         let alarmsPlaySoundPref =
             document.getElementById("calendar.alarms.playsound");
 
         let items = [document.getElementById("alarmSoundFileField"),
-                     document.getElementById("calendar.prefs.alarm.sound.useDefault"),
-                     document.getElementById("calendar.prefs.alarm.sound.browse"),
-                     document.getElementById("calendar.prefs.alarm.sound.play")];
+            document.getElementById("calendar.prefs.alarm.sound.useDefault"),
+            document.getElementById("calendar.prefs.alarm.sound.browse"),
+            document.getElementById("calendar.prefs.alarm.sound.play")];
 
         for (let i = 0; i < items.length; i++) {
             items[i].disabled = !alarmsPlaySoundPref.value;
         }
     }
 };
--- a/calendar/base/content/today-pane.js
+++ b/calendar/base/content/today-pane.js
@@ -21,18 +21,18 @@ var TodayPane = {
         session: false
     },
 
     /**
      * Load Handler, sets up the today pane controls.
      */
     onLoad: function() {
         TodayPane.paneViews = [cal.calGetString("calendar", "eventsandtasks"),
-                               cal.calGetString("calendar", "tasksonly"),
-                               cal.calGetString("calendar", "eventsonly")];
+            cal.calGetString("calendar", "tasksonly"),
+            cal.calGetString("calendar", "eventsonly")];
         agendaListbox.setupCalendar();
         TodayPane.initializeMiniday();
         TodayPane.setShortWeekdays();
 
         document.getElementById("modeBroadcaster").addEventListener("DOMAttrModified", TodayPane.onModeModified, false);
         TodayPane.setTodayHeader();
 
         document.getElementById("today-splitter").addEventListener("command", onCalendarViewResize, false);
--- a/calendar/base/modules/calAlarmUtils.jsm
+++ b/calendar/base/modules/calAlarmUtils.jsm
@@ -69,24 +69,22 @@ cal.alarms = {
                 // Handle all day events.  This is kinda weird, because they don't
                 // have a well defined startTime.  We just consider the start/end
                 // to be midnight in the user's timezone.
                 if (returnDate.isDate) {
                     let timezone = cal.calendarDefaultTimezone();
                     // This returns a copy, so no extra cloning needed.
                     returnDate = returnDate.getInTimezone(timezone);
                     returnDate.isDate = false;
+                } else if (returnDate.timezone.tzid == "floating") {
+                    let timezone = cal.calendarDefaultTimezone();
+                    returnDate = returnDate.getInTimezone(timezone);
                 } else {
-                    if (returnDate.timezone.tzid == "floating") {
-                        let timezone = cal.calendarDefaultTimezone();
-                        returnDate = returnDate.getInTimezone(timezone);
-                    } else {
                         // Clone the date to correctly add the duration.
-                        returnDate = returnDate.clone();
-                    }
+                    returnDate = returnDate.clone();
                 }
 
                 returnDate.addDuration(aAlarm.offset);
                 return returnDate;
             }
         }
         return null;
     },
--- a/calendar/base/modules/calAuthUtils.jsm
+++ b/calendar/base/modules/calAuthUtils.jsm
@@ -296,17 +296,17 @@ cal.auth.Prompt.prototype = {
     asyncPromptAuth: function(aChannel,     // nsIChannel
                               aCallback,    // nsIAuthPromptCallback
                               aContext,     // nsISupports
                               aLevel,       // PRUint32
                               aAuthInfo) {  // nsIAuthInformation
         let self = this;
         let promptlistener = {
             onPromptStartAsync: function(callback) {
-              callback.onAuthResult(this.onPromptStart());
+                callback.onAuthResult(this.onPromptStart());
             },
 
             onPromptStart: function() {
                 res = self.promptAuth(aChannel, aLevel, aAuthInfo);
 
                 if (res) {
                     gAuthCache.setAuthInfo(hostKey, aAuthInfo);
                     this.onPromptAuthAvailable();
--- a/calendar/base/modules/calExtract.jsm
+++ b/calendar/base/modules/calExtract.jsm
@@ -357,17 +357,17 @@ Extractor.prototype = {
         this.markContained();
         this.collected = this.collected.sort(this.sort);
 
         return this.collected;
     },
 
     extractDayMonthYear: function(pattern, relation) {
         let alts = this.getRepPatterns(pattern, ["(\\d{1,2})", "(\\d{1,2})",
-                                                 "(\\d{2,4})"]);
+            "(\\d{2,4})"]);
         let res;
         for (let alt in alts) {
             let positions = alts[alt].positions;
             let re = new RegExp(alts[alt].pattern, "ig");
 
             while ((res = re.exec(this.email)) != null) {
                 if (!this.limitNums(res, this.email) && !this.limitChars(res, this.email)) {
                     let day = parseInt(res[positions[1]], 10);
@@ -382,18 +382,18 @@ Extractor.prototype = {
                     }
                 }
             }
         }
     },
 
     extractDayMonthNameYear: function(pattern, relation) {
         let alts = this.getRepPatterns(pattern, ["(\\d{1,2})",
-                                                 "(" + this.allMonths + ")",
-                                                 "(\\d{2,4})"]);
+            "(" + this.allMonths + ")",
+            "(\\d{2,4})"]);
         let res;
         for (let alt in alts) {
             let exp = alts[alt].pattern.split(this.marker).join("|");
             let positions = alts[alt].positions;
             let re = new RegExp(exp, "ig");
 
             while ((res = re.exec(this.email)) != null) {
                 if (!this.limitNums(res, this.email) && !this.limitChars(res, this.email)) {
@@ -427,18 +427,18 @@ Extractor.prototype = {
                            null, null,
                            rev.start, rev.end, rev.pattern, rev.relation, pattern);
             }
         }
     },
 
     extractDayMonthName: function(pattern, relation) {
         let alts = this.getRepPatterns(pattern,
-                                       ["(\\d{1,2}" + this.marker + this.dailyNumbers + ")",
-                                       "(" + this.allMonths + ")"]);
+            ["(\\d{1,2}" + this.marker + this.dailyNumbers + ")",
+                "(" + this.allMonths + ")"]);
         let res;
         for (let alt in alts) {
             let exp = alts[alt].pattern.split(this.marker).join("|");
             let positions = alts[alt].positions;
             let re = new RegExp(exp, "ig");
 
             while ((res = re.exec(this.email)) != null) {
                 if (!this.limitNums(res, this.email) && !this.limitChars(res, this.email)) {
--- a/calendar/base/modules/calItipUtils.jsm
+++ b/calendar/base/modules/calItipUtils.jsm
@@ -274,18 +274,18 @@ cal.itip = {
         let imipLabel = null;
         if (itipItem.receivedMethod) {
             imipLabel = cal.itip.getMethodText(itipItem.receivedMethod);
         }
         let data = { label: imipLabel, buttons: [], hideMenuItems: [] };
 
         let disallowedCounter = false;
         if (foundItems && foundItems.length) {
-             let disallow = foundItems[0].getProperty("X-MICROSOFT-DISALLOW-COUNTER");
-             disallowedCounter = disallow && disallow == "TRUE";
+            let disallow = foundItems[0].getProperty("X-MICROSOFT-DISALLOW-COUNTER");
+            disallowedCounter = disallow && disallow == "TRUE";
         }
         if (rc == Components.interfaces.calIErrors.CAL_IS_READONLY) {
             // No writable calendars, tell the user about it
             data.label = _gs("imipBarNotWritable");
         } else if (Components.isSuccessCode(rc) && !actionFunc) {
             // This case, they clicked on an old message that has already been
             // added/updated, we want to tell them that.
             data.label = _gs("imipBarAlreadyProcessedText");
--- a/calendar/base/modules/calRecurrenceUtils.jsm
+++ b/calendar/base/modules/calRecurrenceUtils.jsm
@@ -51,24 +51,24 @@ function recurrenceRule2String(recurrenc
     // than a single rule or something other than a rule.
     recurrenceInfo = recurrenceInfo.clone();
     let rrules = splitRecurrenceRules(recurrenceInfo);
     if (rrules[0].length == 1) {
         let rule = cal.wrapInstance(rrules[0][0], Components.interfaces.calIRecurrenceRule);
         // Currently we allow only for BYDAY, BYMONTHDAY, BYMONTH rules.
         if (rule &&
             !checkRecurrenceRule(rule, ["BYSECOND",
-                                        "BYMINUTE",
+                "BYMINUTE",
                                         // "BYDAY",
-                                        "BYHOUR",
+                "BYHOUR",
                                         // "BYMONTHDAY",
-                                        "BYYEARDAY",
-                                        "BYWEEKNO",
+                "BYYEARDAY",
+                "BYWEEKNO",
                                         // "BYMONTH",
-                                        "BYSETPOS"])) {
+                "BYSETPOS"])) {
             let dateFormatter = cal.getDateFormatter();
             let ruleString;
             if (rule.type == "DAILY") {
                 if (checkRecurrenceRule(rule, ["BYDAY"])) {
                     let days = rule.getComponent("BYDAY", {});
                     let weekdays = [2, 3, 4, 5, 6];
                     if (weekdays.length == days.length) {
                         let i;
@@ -314,55 +314,55 @@ function recurrenceRule2String(recurrenc
             let kDefaultTimezone = cal.calendarDefaultTimezone();
 
             let detailsString;
             if (!endDate || allDay) {
                 if (rule.isFinite) {
                     if (rule.isByCount) {
                         let countString = getRString("repeatCountAllDay",
                             [ruleString,
-                             dateFormatter.formatDateShort(startDate)]);
+                                dateFormatter.formatDateShort(startDate)]);
                         detailsString = PluralForm.get(rule.count, countString)
                                                   .replace("#3", rule.count);
                     } else {
                         let untilDate = rule.untilDate.getInTimezone(kDefaultTimezone);
                         detailsString = getRString("repeatDetailsUntilAllDay",
                             [ruleString,
-                             dateFormatter.formatDateShort(startDate),
-                             dateFormatter.formatDateShort(untilDate)]);
+                                dateFormatter.formatDateShort(startDate),
+                                dateFormatter.formatDateShort(untilDate)]);
                     }
                 } else {
                     detailsString = getRString("repeatDetailsInfiniteAllDay",
-                                               [ruleString,
-                                                dateFormatter.formatDateShort(startDate)]);
+                        [ruleString,
+                            dateFormatter.formatDateShort(startDate)]);
                 }
             } else if (rule.isFinite) {
                 if (rule.isByCount) {
                     let countString = getRString("repeatCount",
                         [ruleString,
-                         dateFormatter.formatDateShort(startDate),
-                         dateFormatter.formatTime(startDate),
-                         dateFormatter.formatTime(endDate)]);
+                            dateFormatter.formatDateShort(startDate),
+                            dateFormatter.formatTime(startDate),
+                            dateFormatter.formatTime(endDate)]);
                     detailsString = PluralForm.get(rule.count, countString)
                                               .replace("#5", rule.count);
                 } else {
                     let untilDate = rule.untilDate.getInTimezone(kDefaultTimezone);
                     detailsString = getRString("repeatDetailsUntil",
                         [ruleString,
-                         dateFormatter.formatDateShort(startDate),
-                         dateFormatter.formatDateShort(untilDate),
-                         dateFormatter.formatTime(startDate),
-                         dateFormatter.formatTime(endDate)]);
+                            dateFormatter.formatDateShort(startDate),
+                            dateFormatter.formatDateShort(untilDate),
+                            dateFormatter.formatTime(startDate),
+                            dateFormatter.formatTime(endDate)]);
                 }
             } else {
                 detailsString = getRString("repeatDetailsInfinite",
                     [ruleString,
-                     dateFormatter.formatDateShort(startDate),
-                     dateFormatter.formatTime(startDate),
-                     dateFormatter.formatTime(endDate)]);
+                        dateFormatter.formatDateShort(startDate),
+                        dateFormatter.formatTime(startDate),
+                        dateFormatter.formatTime(endDate)]);
             }
             return detailsString;
         }
     }
     return null;
 }
 
 /**
--- a/calendar/base/modules/calUtils.jsm
+++ b/calendar/base/modules/calUtils.jsm
@@ -90,29 +90,29 @@ var cal = {
      *  - calICompositeObserver
      */
     createAdapter: function(iface, template) {
         let methods;
         let adapter = template || {};
         switch (iface.name || iface) {
             case "calIObserver":
                 methods = ["onStartBatch", "onEndBatch", "onLoad", "onAddItem",
-                           "onModifyItem", "onDeleteItem", "onError",
-                           "onPropertyChanged", "onPropertyDeleting"];
+                    "onModifyItem", "onDeleteItem", "onError",
+                    "onPropertyChanged", "onPropertyDeleting"];
                 break;
             case "calICalendarManagerObserver":
                 methods = ["onCalendarRegistered", "onCalendarUnregistering",
-                           "onCalendarDeleting"];
+                    "onCalendarDeleting"];
                 break;
             case "calIOperationListener":
                 methods = ["onGetResult", "onOperationComplete"];
                 break;
             case "calICompositeObserver":
                 methods = ["onCalendarAdded", "onCalendarRemoved",
-                           "onDefaultCalendarChanged"];
+                    "onDefaultCalendarChanged"];
                 break;
             default:
                 methods = [];
                 break;
         }
 
         for (let method of methods) {
             if (!(method in template)) {
--- a/calendar/base/src/calAlarm.js
+++ b/calendar/base/src/calAlarm.js
@@ -61,19 +61,19 @@ calAlarm.prototype = {
     },
 
     makeImmutable: function() {
         if (this.mImmutable) {
             return;
         }
 
         const objectMembers = ["mAbsoluteDate",
-                               "mOffset",
-                               "mDuration",
-                               "mLastAck"];
+            "mOffset",
+            "mDuration",
+            "mLastAck"];
         for (let member of objectMembers) {
             if (this[member] && this[member].isMutable) {
                 this[member].makeImmutable();
             }
         }
 
         // Properties
         let e = this.mProperties.enumerator;
@@ -91,28 +91,28 @@ calAlarm.prototype = {
     },
 
     clone: function() {
         let cloned = new calAlarm();
 
         cloned.mImmutable = false;
 
         const simpleMembers = ["mAction",
-                               "mSummary",
-                               "mDescription",
-                               "mRelated",
-                               "mRepeat"];
+            "mSummary",
+            "mDescription",
+            "mRelated",
+            "mRepeat"];
 
         const arrayMembers = ["mAttendees",
-                              "mAttachments"];
+            "mAttachments"];
 
         const objectMembers = ["mAbsoluteDate",
-                               "mOffset",
-                               "mDuration",
-                               "mLastAck"];
+            "mOffset",
+            "mDuration",
+            "mLastAck"];
 
         for (let member of simpleMembers) {
             cloned[member] = this[member];
         }
 
         for (let member of arrayMembers) {
             let newArray = [];
             for (let oldElem of this[member]) {
--- a/calendar/base/src/calAttendee.js
+++ b/calendar/base/src/calAttendee.js
@@ -39,17 +39,17 @@ calAttendee.prototype = {
     clone: function() {
         let a = new calAttendee();
 
         if (this.mIsOrganizer) {
             a.isOrganizer = true;
         }
 
         const allProps = ["id", "commonName", "rsvp", "role",
-                          "participationStatus", "userType"];
+            "participationStatus", "userType"];
         for (let prop of allProps) {
             a[prop] = this[prop];
         }
 
         for (let [key, value] of this.mProperties) {
             a.setProperty(key, value);
         }
 
--- a/calendar/base/src/calCachedCalendar.js
+++ b/calendar/base/src/calCachedCalendar.js
@@ -871,15 +871,15 @@ calCachedCalendar.prototype = {
             };
         }
         functions.forEach(defineForwardFunction);
         getters.forEach(defineForwardGetter);
         gettersAndSetters.forEach(defineForwardGetterAndSetter);
     }
 
     defineForwards(calCachedCalendar.prototype, "mUncachedCalendar",
-                   ["setProperty", "deleteProperty",
-                    "isInvitation", "getInvitedAttendee", "canNotify"],
+        ["setProperty", "deleteProperty",
+            "isInvitation", "getInvitedAttendee", "canNotify"],
                    ["type", "aclManager", "aclEntry"],
                    ["id", "name", "uri", "readOnly"]);
     defineForwards(calCachedCalendar.prototype, "mCachedCalendar",
                    ["getItem", "getItems", "startBatch", "endBatch"], [], []);
 })();
--- a/calendar/base/src/calDateTimeFormatter.js
+++ b/calendar/base/src/calDateTimeFormatter.js
@@ -33,17 +33,17 @@ calDateTimeFormatter.prototype = {
         return this._inTimezone(aDate, { dateStyle: "short" });
     },
 
     formatDateLong: function(aDate) {
         return this._inTimezone(aDate, { dateStyle: "full" });
     },
 
     formatDateWithoutYear: function(aDate) {
-        let dtOptions = { month: 'short', day: 'numeric' };
+        let dtOptions = { month: "short", day: "numeric" };
         return this._inTimezone(aDate, dtOptions);
     },
 
     formatTime: function(aDate) {
         if (aDate.isDate) {
             return this.mDateStringBundle.GetStringFromName("AllDay");
         }
 
--- a/calendar/base/src/calFilter.js
+++ b/calendar/base/src/calFilter.js
@@ -177,18 +177,18 @@ calFilter.prototype = {
     mTomorrow: null,
     mMaxIterations: 50,
 
     /**
      * Initializes the predefined filters.
      */
     initDefinedFilters: function() {
         let filters = ["all", "notstarted", "overdue", "open", "completed", "throughcurrent",
-                       "throughtoday", "throughsevendays", "today", "thisCalendarMonth",
-                       "future", "current", "currentview"];
+            "throughtoday", "throughsevendays", "today", "thisCalendarMonth",
+            "future", "current", "currentview"];
         filters.forEach(function(filter) {
             if (!(filter in this.mDefinedFilters)) {
                 this.defineFilter(filter, this.getPreDefinedFilterProperties(filter));
             }
         }, this);
     },
 
     /**
--- a/calendar/base/src/calItemBase.js
+++ b/calendar/base/src/calItemBase.js
@@ -77,18 +77,18 @@ calItemBase.prototype = {
 
     // readonly attribute AUTF8String hashId;
     get hashId() {
         if (this.mHashId === null) {
             let rid = this.recurrenceId;
             let calendar = this.calendar;
             // some unused delim character:
             this.mHashId = [encodeURIComponent(this.id),
-                            rid ? rid.getInTimezone(cal.UTC()).icalString : "",
-                            calendar ? encodeURIComponent(calendar.id) : ""].join("#");
+                rid ? rid.getInTimezone(cal.UTC()).icalString : "",
+                calendar ? encodeURIComponent(calendar.id) : ""].join("#");
         }
         return this.mHashId;
     },
 
     // attribute AUTF8String id;
     get id() {
         return this.getProperty("UID");
     },
--- a/calendar/base/src/calUtils.js
+++ b/calendar/base/src/calUtils.js
@@ -505,29 +505,29 @@ function setupDefaultCategories() {
  * @param str           The string to hash into a color.
  * @return              The hashed color.
  */
 function hashColor(str) {
     // This is the palette of colors in the current colorpicker implementation.
     // Unfortunately, there is no easy way to extract these colors from the
     // binding directly.
     const colorPalette = ["#FFFFFF", "#FFCCCC", "#FFCC99", "#FFFF99", "#FFFFCC",
-                          "#99FF99", "#99FFFF", "#CCFFFF", "#CCCCFF", "#FFCCFF",
-                          "#CCCCCC", "#FF6666", "#FF9966", "#FFFF66", "#FFFF33",
-                          "#66FF99", "#33FFFF", "#66FFFF", "#9999FF", "#FF99FF",
-                          "#C0C0C0", "#FF0000", "#FF9900", "#FFCC66", "#FFFF00",
-                          "#33FF33", "#66CCCC", "#33CCFF", "#6666CC", "#CC66CC",
-                          "#999999", "#CC0000", "#FF6600", "#FFCC33", "#FFCC00",
-                          "#33CC00", "#00CCCC", "#3366FF", "#6633FF", "#CC33CC",
-                          "#666666", "#990000", "#CC6600", "#CC9933", "#999900",
-                          "#009900", "#339999", "#3333FF", "#6600CC", "#993399",
-                          "#333333", "#660000", "#993300", "#996633", "#666600",
-                          "#006600", "#336666", "#000099", "#333399", "#663366",
-                          "#000000", "#330000", "#663300", "#663333", "#333300",
-                          "#003300", "#003333", "#000066", "#330099", "#330033"];
+        "#99FF99", "#99FFFF", "#CCFFFF", "#CCCCFF", "#FFCCFF",
+        "#CCCCCC", "#FF6666", "#FF9966", "#FFFF66", "#FFFF33",
+        "#66FF99", "#33FFFF", "#66FFFF", "#9999FF", "#FF99FF",
+        "#C0C0C0", "#FF0000", "#FF9900", "#FFCC66", "#FFFF00",
+        "#33FF33", "#66CCCC", "#33CCFF", "#6666CC", "#CC66CC",
+        "#999999", "#CC0000", "#FF6600", "#FFCC33", "#FFCC00",
+        "#33CC00", "#00CCCC", "#3366FF", "#6633FF", "#CC33CC",
+        "#666666", "#990000", "#CC6600", "#CC9933", "#999900",
+        "#009900", "#339999", "#3333FF", "#6600CC", "#993399",
+        "#333333", "#660000", "#993300", "#996633", "#666600",
+        "#006600", "#336666", "#000099", "#333399", "#663366",
+        "#000000", "#330000", "#663300", "#663333", "#333300",
+        "#003300", "#003333", "#000066", "#330099", "#330033"];
 
     let sum = Array.from(str || " ", e => e.charCodeAt(0)).reduce((a, b) => a + b);
     return colorPalette[sum % colorPalette.length];
 }
 
 /**
  * Convert categories string to list of category names.
  *
@@ -1534,17 +1534,17 @@ function calIterateEmailIdentities(func)
  * @param aIgnoreProps      (optional) An array of parameters to ignore.
  * @param aIgnoreParams     (optional) An object describing which parameters to
  *                                     ignore.
  * @return                  True, if items match.
  */
 function compareItemContent(aFirstItem, aSecondItem, aIgnoreProps, aIgnoreParams) {
     let ignoreProps = arr2hash(aIgnoreProps ||
         ["SEQUENCE", "DTSTAMP", "LAST-MODIFIED", "X-MOZ-GENERATION", "X-MICROSOFT-DISALLOW-COUNTER",
-         "X-MOZ-SEND-INVITATIONS", "X-MOZ-SEND-INVITATIONS-UNDISCLOSED"]);
+            "X-MOZ-SEND-INVITATIONS", "X-MOZ-SEND-INVITATIONS-UNDISCLOSED"]);
 
     let ignoreParams = aIgnoreParams ||
         { ATTENDEE: ["CN"], ORGANIZER: ["CN"] };
     for (let x in ignoreParams) {
         ignoreParams[x] = arr2hash(ignoreParams[x]);
     }
 
     function arr2hash(arr) {
--- a/calendar/lightning/content/lightning-item-iframe.js
+++ b/calendar/lightning/content/lightning-item-iframe.js
@@ -1255,23 +1255,23 @@ function getRepeatTypeAndUntilDate(aItem
             }
         }
         if (rules.length == 1) {
             let rule = cal.wrapInstance(rules[0], Components.interfaces.calIRecurrenceRule);
             if (rule) {
                 switch (rule.type) {
                     case "DAILY":
                         if (!checkRecurrenceRule(rule, ["BYSECOND",
-                                                        "BYMINUTE",
-                                                        "BYHOUR",
-                                                        "BYMONTHDAY",
-                                                        "BYYEARDAY",
-                                                        "BYWEEKNO",
-                                                        "BYMONTH",
-                                                        "BYSETPOS"])) {
+                            "BYMINUTE",
+                            "BYHOUR",
+                            "BYMONTHDAY",
+                            "BYYEARDAY",
+                            "BYWEEKNO",
+                            "BYMONTH",
+                            "BYSETPOS"])) {
                             let ruleComp = rule.getComponent("BYDAY", {});
                             if (rule.interval == 1) {
                                 if (ruleComp.length > 0) {
                                     if (ruleComp.length == 5) {
                                         let found = false;
                                         for (let i = 0; i < 5; i++) {
                                             if (ruleComp[i] != i + 2) {
                                                 found = true;
@@ -1287,58 +1287,58 @@ function getRepeatTypeAndUntilDate(aItem
                                     repeatType = "daily";
                                     updateUntilDate(rule);
                                 }
                             }
                         }
                         break;
                     case "WEEKLY":
                         if (!checkRecurrenceRule(rule, ["BYSECOND",
-                                                        "BYMINUTE",
-                                                        "BYDAY",
-                                                        "BYHOUR",
-                                                        "BYMONTHDAY",
-                                                        "BYYEARDAY",
-                                                        "BYWEEKNO",
-                                                        "BYMONTH",
-                                                        "BYSETPOS"])) {
+                            "BYMINUTE",
+                            "BYDAY",
+                            "BYHOUR",
+                            "BYMONTHDAY",
+                            "BYYEARDAY",
+                            "BYWEEKNO",
+                            "BYMONTH",
+                            "BYSETPOS"])) {
                             let weekType=["weekly", "bi.weekly"];
                             if ((rule.interval == 1 || rule.interval == 2) &&
                                 (!rule.isFinite || !rule.isByCount)) {
                                 repeatType = weekType[rule.interval - 1];
                                 updateUntilDate(rule);
                             }
                         }
                         break;
                     case "MONTHLY":
                         if (!checkRecurrenceRule(rule, ["BYSECOND",
-                                                        "BYMINUTE",
-                                                        "BYDAY",
-                                                        "BYHOUR",
-                                                        "BYMONTHDAY",
-                                                        "BYYEARDAY",
-                                                        "BYWEEKNO",
-                                                        "BYMONTH",
-                                                        "BYSETPOS"])) {
+                            "BYMINUTE",
+                            "BYDAY",
+                            "BYHOUR",
+                            "BYMONTHDAY",
+                            "BYYEARDAY",
+                            "BYWEEKNO",
+                            "BYMONTH",
+                            "BYSETPOS"])) {
                             if (rule.interval == 1 && (!rule.isFinite || !rule.isByCount)) {
                                 repeatType = "monthly";
                                 updateUntilDate(rule);
                             }
                         }
                         break;
                     case "YEARLY":
                         if (!checkRecurrenceRule(rule, ["BYSECOND",
-                                                        "BYMINUTE",
-                                                        "BYDAY",
-                                                        "BYHOUR",
-                                                        "BYMONTHDAY",
-                                                        "BYYEARDAY",
-                                                        "BYWEEKNO",
-                                                        "BYMONTH",
-                                                        "BYSETPOS"])) {
+                            "BYMINUTE",
+                            "BYDAY",
+                            "BYHOUR",
+                            "BYMONTHDAY",
+                            "BYYEARDAY",
+                            "BYWEEKNO",
+                            "BYMONTH",
+                            "BYSETPOS"])) {
                             if (rule.interval == 1 && (!rule.isFinite || !rule.isByCount)) {
                                 repeatType = "yearly";
                                 updateUntilDate(rule);
                             }
                         }
                         break;
                 }
             }
--- a/calendar/lightning/content/lightning-item-panel.js
+++ b/calendar/lightning/content/lightning-item-panel.js
@@ -731,22 +731,22 @@ function editStatus(aTarget) {
 /**
  * Update the dialog controls related to status.
  *
  * @param {Object} aArg         Contains the new status value
  * @param {string} aArg.status  The new status value
  */
 function updateStatus(aArg) {
     const statusLabels = ["status-status-tentative-label",
-                          "status-status-confirmed-label",
-                          "status-status-cancelled-label"];
+        "status-status-confirmed-label",
+        "status-status-cancelled-label"];
     const commands = ["cmd_status_none",
-                      "cmd_status_tentative",
-                      "cmd_status_confirmed",
-                      "cmd_status_cancelled"];
+        "cmd_status_tentative",
+        "cmd_status_confirmed",
+        "cmd_status_cancelled"];
     let found = false;
     setBooleanAttribute("status-status", "collapsed", true);
     commands.forEach((aElement, aIndex, aArray) => {
         let node = document.getElementById(aElement);
         let matches = (node.getAttribute("value") == aArg.status);
         found = found || matches;
 
         node.setAttribute("checked", matches ? "true" : "false");
--- a/calendar/lightning/content/messenger-overlay-sidebar.js
+++ b/calendar/lightning/content/messenger-overlay-sidebar.js
@@ -540,23 +540,23 @@ function refreshUIBits() {
     try {
         getMinimonth().refreshDisplay();
 
         // Refresh the current view and just allow the refresh for the others
         // views when will be displayed.
         let currView = currentView();
         currView.goToDay();
         ["day-view",
-         "week-view",
-         "multiweek-view",
-         "month-view"].forEach((view) => {
-             if (view != currView.id) {
-                 document.getElementById(view).mToggleStatus = -1;
-             }
-         });
+            "week-view",
+            "multiweek-view",
+            "month-view"].forEach((view) => {
+                if (view != currView.id) {
+                    document.getElementById(view).mToggleStatus = -1;
+                }
+            });
 
         if (!TodayPane.showsToday()) {
             TodayPane.setDay(cal.now());
         }
 
         // update the unifinder
         refreshEventTree();
 
--- a/calendar/lightning/modules/ltnInvitationUtils.jsm
+++ b/calendar/lightning/modules/ltnInvitationUtils.jsm
@@ -407,17 +407,17 @@ ltn.invitation = {
                 }
             }
         }
         aOldDoc = cal.xml.parseString(aOldDoc);
         aNewDoc = cal.xml.parseString(aNewDoc);
         let doc = aNewDoc.cloneNode(true);
         // elements to consider for comparison
         ["summary", "location", "when", "canceledOccurrences",
-         "modifiedOccurrences", "organizer", "attendee"].forEach(_compareElement);
+            "modifiedOccurrences", "organizer", "attendee"].forEach(_compareElement);
         return cal.xml.serializeDOM(doc);
     },
 
     /**
      * Returns the header section for an invitation email.
      * @param   {String}         aMessageId  the message id to use for that email
      * @param   {nsIMsgIdentity} aIdentity   the identity to use for that email
      * @returns {String}                     the source code of the header section of the email
--- a/calendar/providers/caldav/calDavCalendar.js
+++ b/calendar/providers/caldav/calDavCalendar.js
@@ -189,20 +189,20 @@ calDavCalendar.prototype = {
             } finally {
                 this.mOfflineStorage.endBatch();
             }
         }
     },
 
     get offlineCachedProperties() {
         return ["mAuthScheme", "mAuthRealm", "mHasWebdavSyncSupport",
-                "mCtag", "mWebdavSyncToken", "mSupportedItemTypes",
-                "mPrincipalUrl", "mCalHomeSet",
-                "mShouldPollInbox", "hasAutoScheduling", "mHaveScheduling",
-                "mCalendarUserAddress", "mOutboxUrl", "hasFreeBusy"];
+            "mCtag", "mWebdavSyncToken", "mSupportedItemTypes",
+            "mPrincipalUrl", "mCalHomeSet",
+            "mShouldPollInbox", "hasAutoScheduling", "mHaveScheduling",
+            "mCalendarUserAddress", "mOutboxUrl", "hasFreeBusy"];
     },
 
     get checkedServerInfo() {
         if (Services.io.offline) {
             return true;
         } else {
             return this.mCheckedServerInfo;
         }
--- a/calendar/providers/storage/calStorageCalendar.js
+++ b/calendar/providers/storage/calStorageCalendar.js
@@ -278,20 +278,20 @@ calStorageCalendar.prototype = {
                  * Helper function to migrate all tables from one id to the next
                  *
                  * @param db        The database to use
                  * @param newCalId  The new calendar id to set
                  * @param oldCalId  The old calendar id to look for
                  */
                 let migrateTables = function(db, newCalId, oldCalId) {
                     for (let tbl of ["cal_alarms", "cal_attachments",
-                                     "cal_attendees", "cal_events",
-                                     "cal_metadata", "cal_properties",
-                                     "cal_recurrence", "cal_relations",
-                                     "cal_todos"]) {
+                        "cal_attendees", "cal_events",
+                        "cal_metadata", "cal_properties",
+                        "cal_recurrence", "cal_relations",
+                        "cal_todos"]) {
                         let stmt;
                         try {
                             stmt = db.createStatement("UPDATE " + tbl +
                                                       "   SET cal_id = :cal_id" +
                                                       " WHERE cal_id = :old_cal_id");
                             stmt.params.cal_id = newCalId;
                             stmt.params.old_cal_id = oldCalId;
                             stmt.executeStep();
@@ -1384,19 +1384,19 @@ calStorageCalendar.prototype = {
                 "DELETE FROM cal_metadata WHERE item_id = :item_id AND cal_id = :cal_id"
                 );
             this.mDeleteAlarms = this.mDB.createStatement(
                 "DELETE FROM cal_alarms WHERE item_id = :item_id AND cal_id = :cal_id"
                 );
 
             // These are only used when deleting an entire calendar
             let extrasTables = ["cal_attendees", "cal_properties",
-                                "cal_recurrence", "cal_attachments",
-                                "cal_metadata", "cal_relations",
-                                "cal_alarms"];
+                "cal_recurrence", "cal_attachments",
+                "cal_metadata", "cal_relations",
+                "cal_alarms"];
 
             this.mDeleteEventExtras = [];
             this.mDeleteTodoExtras = [];
 
             for (let table in extrasTables) {
                 this.mDeleteEventExtras[table] = this.mDB.createStatement(
                     "DELETE FROM " + extrasTables[table] + " WHERE item_id IN" +
                     "  (SELECT id FROM cal_events WHERE cal_id = :cal_id)" +
--- a/calendar/providers/storage/calStorageUpgrade.jsm
+++ b/calendar/providers/storage/calStorageUpgrade.jsm
@@ -745,34 +745,34 @@ upgrade.v3 = function(db, version) { // 
     beginTransaction(db);
     try {
         copyTable(tbl, "cal_items", "cal_events", db, "item_type = 0");
         copyTable(tbl, "cal_items", "cal_todos", db, "item_type = 1");
 
         dropTable(tbl, "cal_items", db);
 
         let removeEventCols = ["item_type",
-                               "item_type",
-                               "todo_entry",
-                               "todo_due",
-                               "todo_completed",
-                               "todo_complete",
-                               "alarm_id"];
+            "item_type",
+            "todo_entry",
+            "todo_due",
+            "todo_completed",
+            "todo_complete",
+            "alarm_id"];
         deleteColumns(tbl, "cal_events", removeEventCols, db);
 
         addColumn(tbl, "cal_events", "event_start_tz", "VARCHAR", db);
         addColumn(tbl, "cal_events", "event_end_tz", "VARCHAR", db);
         addColumn(tbl, "cal_events", "alarm_time", "INTEGER", db);
         addColumn(tbl, "cal_events", "alarm_time_tz", "VARCHAR", db);
 
         let removeTodoCols = ["item_type",
-                              "event_start",
-                              "event_end",
-                              "event_stamp",
-                              "alarm_id"];
+            "event_start",
+            "event_end",
+            "event_stamp",
+            "alarm_id"];
         deleteColumns(tbl, "cal_todos", removeTodoCols, db);
 
         addColumn(tbl, "cal_todos", "todo_entry_tz", "VARCHAR", db);
         addColumn(tbl, "cal_todos", "todo_due_tz", "VARCHAR", db);
         addColumn(tbl, "cal_todos", "todo_completed_tz", "VARCHAR", db);
         addColumn(tbl, "cal_todos", "alarm_time", "INTEGER", db);
         addColumn(tbl, "cal_todos", "alarm_time_tz", "VARCHAR", db);
 
@@ -852,33 +852,33 @@ upgrade.v5 = function(db, version) { // 
  */
 upgrade.v6 = function(db, version) { // eslint-disable-line id-length
     let tbl = upgrade.v5(version < 5 && db, version);
     LOGdb(db, "Storage: Upgrading to v6");
 
     beginTransaction(db);
     try {
         let eventCols = ["id", "title", "privacy", "ical_status",
-                         "recurrence_id_tz", "event_start_tz",
-                         "event_end_tz", "alarm_time_tz"];
+            "recurrence_id_tz", "event_start_tz",
+            "event_end_tz", "alarm_time_tz"];
         alterTypes(tbl, "cal_events", eventCols, "TEXT", db);
 
         let todoCols = ["id", "title", "privacy", "ical_status",
-                         "recurrence_id_tz", "todo_entry_tz",
-                         "todo_due_tz", "todo_completed_tz",
-                         "alarm_time_tz"];
+            "recurrence_id_tz", "todo_entry_tz",
+            "todo_due_tz", "todo_completed_tz",
+            "alarm_time_tz"];
         alterTypes(tbl, "cal_todos", todoCols, "TEXT", db);
 
         let attendeeCols = ["item_id", "recurrence_id_tz", "attendee_id",
-                            "common_name", "role", "status", "type"];
+            "common_name", "role", "status", "type"];
         alterTypes(tbl, "cal_attendees", attendeeCols, "TEXT", db);
 
         let recurrenceCols = ["item_id", "recur_type", "dates", "second",
-                              "minute", "hour", "day", "monthday", "yearday",
-                              "weekno", "month", "setpos"];
+            "minute", "hour", "day", "monthday", "yearday",
+            "weekno", "month", "setpos"];
         alterTypes(tbl, "cal_recurrence", recurrenceCols, "TEXT", db);
 
         let propertyCols = ["item_id", "recurrence_id_tz", "key"];
         alterTypes(tbl, "cal_properties", propertyCols, "TEXT", db);
         setDbVersionAndCommit(db, 6);
     } catch (e) {
         throw reportErrorAndRollback(db, e);
     }
@@ -1012,17 +1012,17 @@ upgrade.v13 = function(db, version) {
                     }
                 } finally {
                     stmt.finalize();
                 }
             }
         }
 
         for (let tblid of ["attendees", "recurrence", "properties",
-                           "attachments"]) {
+            "attachments"]) {
             addColumn(tbl, "cal_" + tblid, "cal_id", "INTEGER", db);
 
             for (let itemId in calIds) {
                 executeSimpleSQL(db, "UPDATE cal_" + tblid +
                                      "   SET cal_id = " + calIds[itemId] +
                                      " WHERE item_id = '" + itemId + "'");
             }
         }
@@ -1175,19 +1175,19 @@ upgrade.v16 = function(db, version) {
                              "   SET flags = flags | " + CAL_ITEM_FLAG.HAS_ALARMS +
                              " WHERE id IN" +
                              "  (SELECT item_id " +
                              "     FROM cal_alarms " +
                              "     WHERE cal_alarms.cal_id = cal_todos.cal_id)");
 
         // Remote obsolete columns
         let cols = ["alarm_time",
-                    "alarm_time_tz",
-                    "alarm_offset",
-                    "alarm_related"];
+            "alarm_time_tz",
+            "alarm_offset",
+            "alarm_related"];
         for (let tblid of ["events", "todos"]) {
             deleteColumns(tbl, "cal_" + tblid, cols, db);
         }
 
         setDbVersionAndCommit(db, 16);
     } catch (e) {
         throw reportErrorAndRollback(db, e);
     }
@@ -1316,20 +1316,20 @@ upgrade.v18 = function(db, version) {
  */
 upgrade.v19 = function(db, version) {
     let tbl = upgrade.v18(version < 18 && db, version);
     LOGdb(db, "Storage: Upgrading to v19");
     beginTransaction(db);
     try {
         // Change types of column to TEXT.
         for (let tblName of ["cal_alarms", "cal_attachments",
-                             "cal_attendees", "cal_events",
-                             "cal_metadata", "cal_properties",
-                             "cal_recurrence", "cal_relations",
-                             "cal_todos"]) {
+            "cal_attendees", "cal_events",
+            "cal_metadata", "cal_properties",
+            "cal_recurrence", "cal_relations",
+            "cal_todos"]) {
             alterTypes(tbl, tblName, ["cal_id"], "TEXT", db);
         }
         setDbVersionAndCommit(db, 19);
     } catch (e) {
         throw reportErrorAndRollback(db, e);
     }
 
     return tbl;
@@ -1513,18 +1513,18 @@ upgrade.v22 = function(db, version) {
                     // There are some attendees with a null ID. We are taking
                     // the opportunity to remove them here.
                     cal.ERROR("Error converting attendee, removing: " + e);
                     return null;
                 }
             }
         });
         migrateToIcalString(tbl, "cal_attendees", "translateAttendee",
-                            ["attendee_id", "common_name", "rsvp", "role",
-                             "status", "type", "is_organizer", "properties"], db);
+            ["attendee_id", "common_name", "rsvp", "role",
+                "status", "type", "is_organizer", "properties"], db);
 
         // Update recurrence table to using icalString directly
         createFunction(db, "translateRecurrence", 17, {
             onFunctionCall: function(storArgs) {
                 function parseInt10(x) { return parseInt(x, 10); }
                 try {
                     // eslint-disable-next-line no-unused-vars
                     let [aIndex, aType, aIsNegative, aDates, aCount,
@@ -1606,19 +1606,19 @@ upgrade.v22 = function(db, version) {
                                    "AND e.cal_id = cal_recurrence.cal_id " +
                                  "UNION " +
                                 "SELECT t.flags " +
                                   "FROM cal_todos AS t " +
                                  "WHERE t.id = cal_recurrence.item_id " +
                                    "AND t.cal_id = cal_recurrence.cal_id)");
 
         migrateToIcalString(tbl, "cal_recurrence", "translateRecurrence",
-                            ["recur_index", "recur_type", "is_negative",
-                             "dates", "count", "end_date", "interval", "second",
-                             "minute", "hour", "day", "monthday", "yearday",
-                             "weekno", "month", "setpos", "tmp_date_tz"], db);
+            ["recur_index", "recur_type", "is_negative",
+                "dates", "count", "end_date", "interval", "second",
+                "minute", "hour", "day", "monthday", "yearday",
+                "weekno", "month", "setpos", "tmp_date_tz"], db);
 
         setDbVersionAndCommit(db, 22);
     } catch (e) {
         throw reportErrorAndRollback(db, e);
     }
     return tbl;
 };
--- a/calendar/providers/wcap/calWcapSession.js
+++ b/calendar/providers/wcap/calWcapSession.js
@@ -1038,28 +1038,28 @@ calWcapSession.prototype = {
 
         try {
             // make sure the calendar belongs to this session:
             if (this.belongsTo(aCalendar)) {
                 assureDefault("shared_context", this.m_contextId);
                 assureDefault("name", aCalendar.name);
 
                 const s_colors = ["#FFCCCC", "#FFCC99", "#FFFF99", "#FFFFCC", "#99FF99",
-                                  "#99FFFF", "#CCFFFF", "#CCCCFF", "#FFCCFF", "#FF6666",
-                                  "#FF9966", "#FFFF66", "#FFFF33", "#66FF99", "#33FFFF",
-                                  "#66FFFF", "#9999FF", "#FF99FF", "#FF0000", "#FF9900",
-                                  "#FFCC66", "#FFFF00", "#33FF33", "#66CCCC", "#33CCFF",
-                                  "#6666CC", "#CC66CC", "#CC0000", "#FF6600", "#FFCC33",
-                                  "#FFCC00", "#33CC00", "#00CCCC", "#3366FF", "#6633FF",
-                                  "#CC33CC", "#990000", "#CC6600", "#CC9933", "#999900",
-                                  "#009900", "#339999", "#3333FF", "#6600CC", "#993399",
-                                  "#660000", "#993300", "#996633", "#666600", "#006600",
-                                  "#336666", "#000099", "#333399", "#663366", "#330000",
-                                  "#663300", "#663333", "#333300", "#003300", "#003333",
-                                  "#000066", "#330099", "#330033"];
+                    "#99FFFF", "#CCFFFF", "#CCCCFF", "#FFCCFF", "#FF6666",
+                    "#FF9966", "#FFFF66", "#FFFF33", "#66FF99", "#33FFFF",
+                    "#66FFFF", "#9999FF", "#FF99FF", "#FF0000", "#FF9900",
+                    "#FFCC66", "#FFFF00", "#33FF33", "#66CCCC", "#33CCFF",
+                    "#6666CC", "#CC66CC", "#CC0000", "#FF6600", "#FFCC33",
+                    "#FFCC00", "#33CC00", "#00CCCC", "#3366FF", "#6633FF",
+                    "#CC33CC", "#990000", "#CC6600", "#CC9933", "#999900",
+                    "#009900", "#339999", "#3333FF", "#6600CC", "#993399",
+                    "#660000", "#993300", "#996633", "#666600", "#006600",
+                    "#336666", "#000099", "#333399", "#663366", "#330000",
+                    "#663300", "#663333", "#333300", "#003300", "#003333",
+                    "#000066", "#330099", "#330033"];
                 assureDefault("color", s_colors[(new Date()).getUTCMilliseconds() % s_colors.length]);
             }
         } catch (exc) { // never break the listener chain
             this.notifyError(exc);
         }
     },
 
     // called before the unregister actually takes place
--- a/calendar/test/mozmill/invitations/test-imip-bar-eml.js
+++ b/calendar/test/mozmill/invitations/test-imip-bar-eml.js
@@ -13,17 +13,17 @@ var MODULE_NAME = "invitations";
 var RELATIVE_ROOT = "../shared-modules";
 var MODULE_REQUIRES = [
     "folder-display-helpers",
     "window-helpers",
     "notificationbox-helpers"
 ];
 
 var os = {};
-Components.utils.import('resource://mozmill/stdlib/os.js', os);
+Components.utils.import("resource://mozmill/stdlib/os.js", os);
 
 function setupModule(module) {
     for (let dep of MODULE_REQUIRES) {
         collector.getModule(dep).installInto(module);
     }
 }
 
 /**
@@ -40,9 +40,8 @@ function test_event_from_eml() {
         if (!nb) {
             throw new Error("Couldn't find imip-bar in DOM.");
         }
         return (nb.collapsed === false);
     }, "Timed out waiting for IMIP bar to show");
 
     close_window(msgc);
 }
-
--- a/calendar/test/mozmill/shared-modules/test-calendar-utils.js
+++ b/calendar/test/mozmill/shared-modules/test-calendar-utils.js
@@ -247,17 +247,17 @@ function goToDate(controller, year, mont
             anon({"anonid":"yearcell"})
         `));
 
         let getYearListitem = function(aYear) {
             return lookup(`
                 ${miniMonth}/anon({"anonid":"minimonth-header"})/
                 anon({"anonid":"minmonth-popupset"})/anon({"anonid":"years-popup"})/
                 {"label":"${aYear}"}
-            `)
+            `);
         };
 
         controller.waitForElement(scrollArrow);
         scrollArrow = scrollArrow.getNode();
 
         for (let i = 0; i < Math.abs(yearDifference); i++) {
             scrollArrow.doCommand();
             controller.waitForElement(getYearListitem(
--- a/calendar/test/unit/head_consts.js
+++ b/calendar/test/unit/head_consts.js
@@ -160,19 +160,19 @@ function getProps(aItem, aProp) {
     }
 }
 
 function compareItemsSpecific(aLeftItem, aRightItem, aPropArray) {
     if (!aPropArray) {
         // left out:  "id", "calendar", "lastModifiedTime", "generation",
         // "stampTime" as these are expected to change
         aPropArray = ["start", "end", "duration",
-                      "title", "priority", "privacy", "creationDate",
-                      "status", "alarmLastAck",
-                      "recurrenceStartDate"];
+            "title", "priority", "privacy", "creationDate",
+            "status", "alarmLastAck",
+            "recurrenceStartDate"];
     }
     for (let i = 0; i < aPropArray.length; i++) {
         equal(getProps(aLeftItem, aPropArray[i]),
               getProps(aRightItem, aPropArray[i]),
               Components.stack.caller);
     }
 }
 
--- a/calendar/test/unit/test_alarmservice.js
+++ b/calendar/test/unit/test_alarmservice.js
@@ -247,35 +247,35 @@ function addTestItems(aCalendar) {
 
     // daily repeating event starting almost 2 full days ago. The alarms on the first 2 occurrences
     // should fire, and a timer should be set for the next occurrence only
     date = cal.now();
     date.hour -= 47;
     [item, alarm] = createEventWithAlarm(aCalendar, date, date, "-PT15M", "RRULE:FREQ=DAILY");
     item.title="addTestItems Test 7";
     alarmObserver.expectOccurrences(aCalendar, item, alarm,
-                                   [EXPECT_FIRED, EXPECT_FIRED, EXPECT_TIMER,
-                                    EXPECT_NONE, EXPECT_NONE]);
+        [EXPECT_FIRED, EXPECT_FIRED, EXPECT_TIMER,
+            EXPECT_NONE, EXPECT_NONE]);
     aCalendar.addItem(item, null);
 
     // monthly repeating event starting 2 months and a day ago. The alarms on the first 2 occurrences
     // should be ignored, the alarm on the next occurrence only should fire.
     // Missing recurrences of the event in particular days of the year generate exceptions to the
     // regular sequence of alarms.
     date = cal.now();
     let statusAlarmSequences = {
         reg: [EXPECT_NONE, EXPECT_NONE, EXPECT_FIRED, EXPECT_NONE, EXPECT_NONE],
         excep1: [EXPECT_NONE, EXPECT_FIRED, EXPECT_NONE, EXPECT_NONE, EXPECT_NONE],
         excep2: [EXPECT_NONE, EXPECT_NONE, EXPECT_NONE, EXPECT_NONE, EXPECT_NONE]
     };
     let expected = [];
     if (date.day == 1) {
         // Exceptions for missing occurrences on months with 30 days when the event starts on 31st.
         let sequence = ["excep1", "reg", "excep2", "excep1", "reg", "excep1",
-                        "reg", "excep1", "reg", "excep2", "excep1", "reg"][date.month];
+            "reg", "excep1", "reg", "excep2", "excep1", "reg"][date.month];
         expected = statusAlarmSequences[sequence];
     } else if (date.day == 30 && (date.month == 2 || date.month == 3)) {
         // Exceptions for missing occurrences or different start date caused by February.
         let leapYear = date.endOfYear.yearday == 366;
         expected = leapYear ? statusAlarmSequences.reg : statusAlarmSequences.excep1;
     } else if (date.day == 31 && date.month == 2) {
         // Exceptions for missing occurrences caused by February.
         expected = statusAlarmSequences.excep1;
--- a/calendar/test/unit/test_attendee.js
+++ b/calendar/test/unit/test_attendee.js
@@ -46,17 +46,17 @@ function test_values() {
             equal(a[properties[i]], old);
         }
     }
 
     // Create Attendee
     let attendee1 = cal.createAttendee();
     // Testing attendee set/get.
     let properties = ["id", "commonName", "rsvp", "role", "participationStatus",
-                      "userType"];
+        "userType"];
     let values = ["myid", "mycn", "TRUE", "CHAIR", "DECLINED", "RESOURCE"];
     // Make sure test is valid
     equal(properties.length, values.length);
 
     for (let i = 0; i < properties.length; i++) {
         attendee1[properties[i]] = values[i];
         equal(attendee1[properties[i]], values[i]);
     }
--- a/calendar/test/unit/test_bug1199942.js
+++ b/calendar/test/unit/test_bug1199942.js
@@ -42,19 +42,19 @@ function serializeEvent_test() {
               "ATTENDEE;RSVP=TRUE;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT:urn:uuid:user5\n" +
               "DTSTART:20150729T103000Z\n" +
               "DTEND:20150729T113000Z\n" +
               "TRANSP:OPAQUE\n" +
               "END:VEVENT\n" +
               "END:VCALENDAR\n";
 
     let expectedIds = ["mailto:user2@example.net",
-                       "mailto:user3@example.net",
-                       "mailto:user4@example.net",
-                       "urn:uuid:user5"];
+        "mailto:user3@example.net",
+        "mailto:user4@example.net",
+        "urn:uuid:user5"];
     let event = createEventFromIcalString(ics);
     let attendees = event.getAttendees({});
 
     // check whether all attendees get returned with expected id
     for (let attendee of attendees) {
         ok(expectedIds.includes(attendee.id));
     }
 
--- a/calendar/test/unit/test_bug759324.js
+++ b/calendar/test/unit/test_bug759324.js
@@ -7,21 +7,21 @@
  * still works
  */
 function run_test() {
     let storage = getStorageCal();
 
     storage.setProperty("capabilities.propagate-sequence", "true");
 
     let str = ["BEGIN:VEVENT",
-               "UID:recItem",
-               "SEQUENCE:3",
-               "RRULE:FREQ=WEEKLY",
-               "DTSTART:20120101T010101Z",
-               "END:VEVENT"].join("\r\n");
+        "UID:recItem",
+        "SEQUENCE:3",
+        "RRULE:FREQ=WEEKLY",
+        "DTSTART:20120101T010101Z",
+        "END:VEVENT"].join("\r\n");
 
     let item = createEventFromIcalString(str);
     let rid = cal.createDateTime("20120101T010101Z");
     let rec = item.recurrenceInfo.getOccurrenceFor(rid);
     rec.title = "changed";
     item.recurrenceInfo.modifyException(rec, true);
 
     do_test_pending();
--- a/calendar/test/unit/test_calitiputils.js
+++ b/calendar/test/unit/test_calitiputils.js
@@ -113,17 +113,17 @@ function getSeqStampTestItems(aTest) {
                 xMozReceivedStamp = "X-MOZ-RECEIVED-DTSTAMP:" + input.item.xMozReceivedStamp;
             }
             let xMsAptSeq = "";
             if ("xMsAptSeq" in input.item && input.item.xMsAptSeq.length) {
                 xMsAptSeq = "X-MICROSOFT-CDO-APPT-SEQUENCE:" + input.item.xMsAptSeq;
             }
             let testItem = cal.createEvent();
             testItem.icalString = getSeqStampTestIcs([attendee, sequence, dtStamp, xMozReceivedSeq,
-                                                      xMozReceivedStamp, xMsAptSeq]);
+                xMozReceivedStamp, xMsAptSeq]);
             items.push(testItem);
         } else {
             // in this case, we need to return an attendee
             let att = cal.createAttendee();
             att.id = input.attendee.id || "mailto:otherattendee@example.net";
             if (input.attendee.receivedSeq && input.attendee.receivedSeq.length) {
                 att.setProperty("RECEIVED-SEQUENCE", input.attendee.receivedSeq);
             }
--- a/calendar/test/unit/test_datetimeformatter.js
+++ b/calendar/test/unit/test_datetimeformatter.js
@@ -38,17 +38,17 @@ add_task(function* formatDate_test() {
 
 
     let tzs = cal.getTimezoneService();
 
     let i = 0;
     for (let test of data) {
         i++;
         Preferences.set("calendar.date.format", test.input.dateformat);
-        let tz = (test.input.timezone == 'floating') ? cal.floating() : tzs.getTimezone(test.input.timezone);
+        let tz = (test.input.timezone == "floating") ? cal.floating() : tzs.getTimezone(test.input.timezone);
         let date = cal.createDateTime(test.input.datetime).getInTimezone(tz);
 
         let dtFormatter = Components.classes["@mozilla.org/calendar/datetime-formatter;1"]
                                     .getService(Components.interfaces.calIDateTimeFormatter);
         let formatted = dtFormatter.formatDate(date);
         ok(
             test.expected.includes(formatted),
             "(test #" + i + ": result '" + formatted + "', expected '" + test.expected + "')"
@@ -117,17 +117,17 @@ add_task(function* formatDateShort_test(
     Preferences.set("calendar.date.format", 0);
 
     let tzs = cal.getTimezoneService();
 
     let i = 0;
     for (let test of data) {
         i++;
 
-        let tz = (test.input.timezone == 'floating') ? cal.floating() : tzs.getTimezone(test.input.timezone);
+        let tz = (test.input.timezone == "floating") ? cal.floating() : tzs.getTimezone(test.input.timezone);
         let date = cal.createDateTime(test.input.datetime).getInTimezone(tz);
 
         let dtFormatter = Components.classes["@mozilla.org/calendar/datetime-formatter;1"]
                                     .getService(Components.interfaces.calIDateTimeFormatter);
 
         let formatted = dtFormatter.formatDateShort(date);
         ok(
             test.expected.includes(formatted),
@@ -197,17 +197,17 @@ add_task(function* formatDateLong_test()
     Preferences.set("calendar.date.format", 1);
 
     let tzs = cal.getTimezoneService();
 
     let i = 0;
     for (let test of data) {
         i++;
 
-        let tz = (test.input.timezone == 'floating') ? cal.floating() : tzs.getTimezone(test.input.timezone);
+        let tz = (test.input.timezone == "floating") ? cal.floating() : tzs.getTimezone(test.input.timezone);
         let date = cal.createDateTime(test.input.datetime).getInTimezone(tz);
 
         let dtFormatter = Components.classes["@mozilla.org/calendar/datetime-formatter;1"]
                                     .getService(Components.interfaces.calIDateTimeFormatter);
 
         let formatted = dtFormatter.formatDateLong(date);
         ok(
             test.expected.includes(formatted),
@@ -277,17 +277,17 @@ add_task(function* formatDateWithoutYear
     Preferences.set("calendar.date.format", 1);
 
     let tzs = cal.getTimezoneService();
 
     let i = 0;
     for (let test of data) {
         i++;
 
-        let tz = (test.input.timezone == 'floating') ? cal.floating() : tzs.getTimezone(test.input.timezone);
+        let tz = (test.input.timezone == "floating") ? cal.floating() : tzs.getTimezone(test.input.timezone);
         let date = cal.createDateTime(test.input.datetime).getInTimezone(tz);
 
         let dtFormatter = Components.classes["@mozilla.org/calendar/datetime-formatter;1"]
                                     .getService(Components.interfaces.calIDateTimeFormatter);
 
         equal(dtFormatter.formatDateWithoutYear(date), test.expected, "(test #" + i + ")");
     }
     // let's reset the preferences
@@ -332,17 +332,17 @@ add_task(function* formatTime_test() {
     Preferences.set("calendar.timezone.local", "Pacific/Fakaofo");
 
     let tzs = cal.getTimezoneService();
 
     let i = 0;
     for (let test of data) {
         i++;
 
-        let tz = (test.input.timezone == 'floating') ? cal.floating() : tzs.getTimezone(test.input.timezone);
+        let tz = (test.input.timezone == "floating") ? cal.floating() : tzs.getTimezone(test.input.timezone);
         let date = cal.createDateTime(test.input.datetime).getInTimezone(tz);
 
         let dtFormatter = Components.classes["@mozilla.org/calendar/datetime-formatter;1"]
                                     .getService(Components.interfaces.calIDateTimeFormatter);
 
         let formatted = dtFormatter.formatTime(date);
         ok(
             test.expected.includes(formatted),
--- a/calendar/test/unit/test_ltninvitationutils.js
+++ b/calendar/test/unit/test_ltninvitationutils.js
@@ -110,17 +110,17 @@ add_task(function* getItipHeader_test() 
                         "ROLE=REQ-PARTICIPANT:mailto:attendee1@example.net"]
         },
         expected: "Attendee1 <attendee1@example.net> has declined your event invitation."
     }, {
         input: {
             method: "METHOD:REPLY\r\n",
             attendees: ["ATTENDEE;RSVP=TRUE;CN=Attendee1;PARTSTAT=ACCEPTED;" +
                         "ROLE=REQ-PARTICIPANT:mailto:attendee1@example.net",
-                        "ATTENDEE;RSVP=TRUE;CN=Attendee2;PARTSTAT=DECLINED;" +
+                "ATTENDEE;RSVP=TRUE;CN=Attendee2;PARTSTAT=DECLINED;" +
                         "ROLE=REQ-PARTICIPANT:mailto:attendee2@example.net"]
         },
         expected: "Attendee1 <attendee1@example.net> has accepted your event invitation."
     }, {
         input: {
             method: "METHOD:UNSUPPORTED\r\n",
             attendees: [null]
         },
@@ -443,43 +443,43 @@ add_task(function* compareInvitationOver
             ignore: ""
         },
         expected: {
             // Time format is platform dependent, so we use alternative result sets here.
             // The first two are configurations running for automated tests.
             // If you get a failure for this test, add your pattern here.
             node: "imipHtml-when-content",
             some: // For Windows.
-                  ["<span xmlns=\"\" class=\"added\">Wednesday, September 09, 2015 2:00 PM – 3:00 PM</span>" +
+            ["<span xmlns=\"\" class=\"added\">Wednesday, September 09, 2015 2:00 PM – 3:00 PM</span>" +
                    "<br xmlns=\"\"/>" +
                    "<span xmlns=\"\" class=\"removed\">Wednesday, September 09, 2015 1:00 PM – 2:00 PM</span>",
 
-                   "<span xmlns=\"\" class=\"added\">Wednesday, September 09, 2015 14:00 – 15:00</span>" +
+                "<span xmlns=\"\" class=\"added\">Wednesday, September 09, 2015 14:00 – 15:00</span>" +
                    "<br xmlns=\"\"/>" +
                    "<span xmlns=\"\" class=\"removed\">Wednesday, September 09, 2015 13:00 – 14:00</span>",
 
                    // For Linux and Mac: The same but without 2-digit day.
-                   "<span xmlns=\"\" class=\"added\">Wednesday, September 9, 2015 2:00 PM – 3:00 PM</span>" +
+                "<span xmlns=\"\" class=\"added\">Wednesday, September 9, 2015 2:00 PM – 3:00 PM</span>" +
                    "<br xmlns=\"\"/>" +
                    "<span xmlns=\"\" class=\"removed\">Wednesday, September 9, 2015 1:00 PM – 2:00 PM</span>",
 
-                   "<span xmlns=\"\" class=\"added\">Wednesday, September 9, 2015 14:00 – 15:00</span>" +
+                "<span xmlns=\"\" class=\"added\">Wednesday, September 9, 2015 14:00 – 15:00</span>" +
                    "<br xmlns=\"\"/>" +
                    "<span xmlns=\"\" class=\"removed\">Wednesday, September 9, 2015 13:00 – 14:00</span>"]
         }
     }, {
         input: {
             previous: { organizer: "ORGANIZER:mailto:organizer1@example.net\r\n" },
             current: { organizer: "ORGANIZER:mailto:organizer2@example.net\r\n" },
             ignore: ""
         },
         expected: {
             node: "organizer-table",
             each: ["<span xmlns=\"\" class=\"added\">organizer2@example.net</span>",
-                   "<span xmlns=\"\" class=\"removed\">organizer1@example.net</span>"]
+                "<span xmlns=\"\" class=\"removed\">organizer1@example.net</span>"]
         }
     }, {
         input: {
             previous: {
                 attendee: "ATTENDEE;RSVP=TRUE;CUTYPE=INDIVIDUAL;PARTSTAT=NEEDS-ACTION:" +
                           "mailto:attendee1@example.net\r\n" +
                           "ATTENDEE;RSVP=TRUE;CUTYPE=INDIVIDUAL;PARTSTAT=NEEDS-ACTION:" +
                           "mailto:attendee2@example.net\r\n" +
@@ -494,19 +494,19 @@ add_task(function* compareInvitationOver
                           "ATTENDEE;RSVP=TRUE;CUTYPE=INDIVIDUAL;PARTSTAT=NEEDS-ACTION:" +
                           "mailto:attendee4@example.net\r\n"
             },
             ignore: ""
         },
         expected: {
             node: "attendee-table",
             each: ["<span xmlns=\"\" class=\"modified\">attendee2@example.net</span>",
-                   "attendee3@example.net",
-                   "<span xmlns=\"\" class=\"added\">attendee4@example.net</span>",
-                   "<span xmlns=\"\" class=\"removed\">attendee1@example.net</span>"]
+                "attendee3@example.net",
+                "<span xmlns=\"\" class=\"added\">attendee4@example.net</span>",
+                "<span xmlns=\"\" class=\"removed\">attendee1@example.net</span>"]
         }
     }];
     // we make sure that the Europe/Berlin timezone and long datetime format is set
     let dateformat = Preferences.get("calendar.date.format", 0);
     let tzlocal = Preferences.get("calendar.timezone.local", "Europe/Berlin");
     Preferences.set("calendar.date.format", 0);
     Preferences.set("calendar.timezone.local", "Europe/Berlin");
     let i = 0;
@@ -788,34 +788,20 @@ add_task(function* getRfc5322FormattedDa
 });
 
 add_task(function* parseCounter_test() {
     let data = [{
         // #1: basic test to check all currently supported properties
         input: {
             existing: [],
             proposed: [
-                {
-                    method: "METHOD:COUNTER"
-                }, {
-                    dtStart: "DTSTART;TZID=Europe/Berlin:20150910T210000"
-                }, {
-                    dtEnd: "DTEND;TZID=Europe/Berlin:20150910T220000"
-                }, {
-                    location: "LOCATION:Room 2"
-                }, {
-                    summary: "SUMMARY:Test Event 2"
-                }, {
+                { method: "METHOD:COUNTER" }, { dtStart: "DTSTART;TZID=Europe/Berlin:20150910T210000" }, { dtEnd: "DTEND;TZID=Europe/Berlin:20150910T220000" }, { location: "LOCATION:Room 2" }, { summary: "SUMMARY:Test Event 2" }, {
                     attendee: "ATTENDEE;CN=Attendee;PARTSTAT=DECLINED;ROLE=REQ-PARTICIPANT:" +
                               "mailto:attendee@example.net"
-                }, {
-                    dtStamp: "DTSTAMP:20150909T182048Z"
-                }, {
-                    attach: "COMMENT:Sorry\, I cannot make it that time."
-                }
+                }, { dtStamp: "DTSTAMP:20150909T182048Z" }, { attach: "COMMENT:Sorry\, I cannot make it that time." }
             ]
         },
         expected: {
             // Time format is platform dependent, so we use alternative result sets here.
             // The first two are configurations running for automated tests.
             // If you get a failure for this test, add your pattern here.
             result: { descr: "", type: "OK" },
             differences: [{
@@ -824,189 +810,148 @@ add_task(function* parseCounter_test() {
                 original: "Test Event"
             }, {
                 property: "LOCATION",
                 proposed: "Room 2",
                 original: "Room 1"
             }, {
                 property: "DTSTART",
                 proposed: ["Thursday, September 10, 2015 9:00 PM Europe/Berlin",
-                           "Thursday, September 10, 2015 21:00 Europe/Berlin"],
+                    "Thursday, September 10, 2015 21:00 Europe/Berlin"],
                 original: ["Wednesday, September 09, 2015 9:00 PM Europe/Berlin", // Windows
-                           "Wednesday, September 09, 2015 21:00 Europe/Berlin",
-                           "Wednesday, September 9, 2015 9:00 PM Europe/Berlin",  // Linux and Mac
-                           "Wednesday, September 9, 2015 21:00 Europe/Berlin"]
+                    "Wednesday, September 09, 2015 21:00 Europe/Berlin",
+                    "Wednesday, September 9, 2015 9:00 PM Europe/Berlin",  // Linux and Mac
+                    "Wednesday, September 9, 2015 21:00 Europe/Berlin"]
             }, {
                 property: "DTEND",
                 proposed: ["Thursday, September 10, 2015 10:00 PM Europe/Berlin",
-                           "Thursday, September 10, 2015 22:00 Europe/Berlin"],
+                    "Thursday, September 10, 2015 22:00 Europe/Berlin"],
                 original: ["Wednesday, September 09, 2015 10:00 PM Europe/Berlin", // Windows
-                           "Wednesday, September 09, 2015 22:00 Europe/Berlin",
-                           "Wednesday, September 9, 2015 10:00 PM Europe/Berlin",  // Linux and Mac
-                           "Wednesday, September 9, 2015 22:00 Europe/Berlin"]
+                    "Wednesday, September 09, 2015 22:00 Europe/Berlin",
+                    "Wednesday, September 9, 2015 10:00 PM Europe/Berlin",  // Linux and Mac
+                    "Wednesday, September 9, 2015 22:00 Europe/Berlin"]
             }, {
                 property: "COMMENT",
                 proposed: "Sorry\, I cannot make it that time.",
                 original: null
             }]
         }
     }, {
         // #2: test with an unsupported property has been changed
         input: {
             existing: [],
             proposed: [
-                {
-                    method: "METHOD:COUNTER"
-                }, {
+                { method: "METHOD:COUNTER" }, {
                     attendee: "ATTENDEE;CN=Attendee;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT:" +
                               "mailto:attendee@example.net"
-                }, {
-                    location: "LOCATION:Room 2"
-                }, {
-                    attach: "ATTACH:http://www.example2.com"
-                } ,{
-                    dtStamp: "DTSTAMP:20150909T182048Z"
-                }]
+                }, { location: "LOCATION:Room 2" }, { attach: "ATTACH:http://www.example2.com" }, { dtStamp: "DTSTAMP:20150909T182048Z" }]
         },
         expected: {
             result: { descr: "", type: "OK" },
             differences: [{ property: "LOCATION", proposed: "Room 2", original: "Room 1" }]
         }
     }, {
         // #3: proposed change not based on the latest update of the invitation
         input: {
             existing: [],
             proposed: [
-                {
-                    method: "METHOD:COUNTER"
-                }, {
+                { method: "METHOD:COUNTER" }, {
                     attendee: "ATTENDEE;CN=Attendee;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT:" +
                               "mailto:attendee@example.net"
-                }, {
-                    location: "LOCATION:Room 2"
-                }, {
-                    dtStamp: "DTSTAMP:20150909T171048Z"
-                }
+                }, { location: "LOCATION:Room 2" }, { dtStamp: "DTSTAMP:20150909T171048Z" }
             ]
         },
         expected: {
             result: {
                 descr: "This is a counterproposal not based on the latest event update.",
                 type: "NOTLATESTUPDATE"
             },
             differences: [{ property: "LOCATION", proposed: "Room 2", original: "Room 1" }]
         }
     }, {
         // #4: proposed change based on a meanwhile reschuled invitation
         input: {
             existing: [],
             proposed: [
-                {
-                    method: "METHOD:COUNTER"
-                }, {
+                { method: "METHOD:COUNTER" }, {
                     attendee: "ATTENDEE;CN=Attendee;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT:" +
                               "mailto:attendee@example.net"
-                }, {
-                    location: "LOCATION:Room 2"
-                }, {
-                    sequence: "SEQUENCE:0"
-                }, {
-                    dtStamp: "DTSTAMP:20150909T182048Z"
-                }
+                }, { location: "LOCATION:Room 2" }, { sequence: "SEQUENCE:0" }, { dtStamp: "DTSTAMP:20150909T182048Z" }
             ]
         },
         expected: {
             result: {
                 descr: "This is a counterproposal to an already rescheduled event.",
                 type: "OUTDATED"
             },
             differences: [{ property: "LOCATION", proposed: "Room 2", original: "Room 1" }]
         }
     }, {
         // #5: proposed change for an later sequence of the event
         input: {
             existing: [],
             proposed: [
-                {
-                    method: "METHOD:COUNTER"
-                }, {
+                { method: "METHOD:COUNTER" }, {
                     attendee: "ATTENDEE;CN=Attendee;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT:" +
                               "mailto:attendee@example.net"
-                }, {
-                    location: "LOCATION:Room 2"
-                }, {
-                    sequence: "SEQUENCE:2"
-                }, {
-                    dtStamp: "DTSTAMP:20150909T182048Z"
-                }
+                }, { location: "LOCATION:Room 2" }, { sequence: "SEQUENCE:2" }, { dtStamp: "DTSTAMP:20150909T182048Z" }
             ]
         },
         expected: {
             result: {
                 descr: "Invalid sequence number in counterproposal.",
                 type: "ERROR"
             },
             differences: []
         }
     }, {
         // #6: proposal to a different event
         input: {
             existing: [],
             proposed: [
-                {
-                    method: "METHOD:COUNTER"
-                }, {
-                    uid: "UID:cb189fdc-0000-0000-0000-31a08802249d"
-                }, {
+                { method: "METHOD:COUNTER" }, { uid: "UID:cb189fdc-0000-0000-0000-31a08802249d" }, {
                     attendee: "ATTENDEE;CN=Attendee;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT:" +
                               "mailto:attendee@example.net"
-                }, {
-                    location: "LOCATION:Room 2"
-                }, {
-                    dtStamp: "DTSTAMP:20150909T182048Z"
-                }
+                }, { location: "LOCATION:Room 2" }, { dtStamp: "DTSTAMP:20150909T182048Z" }
             ]
         },
         expected: {
             result: {
                 descr: "Mismatch of uid or organizer in counterproposal.",
                 type: "ERROR"
             },
             differences: []
         }
     }, {
         // #7: proposal with a different organizer
         input: {
             existing: [],
             proposed: [
-                {
-                    method: "METHOD:COUNTER"
-                }, {
+                { method: "METHOD:COUNTER" }, {
                     organizer: "ORGANIZER;RSVP=TRUE;CN=Organizer;PARTSTAT=ACCEPTED;ROLE=CHAI" +
                                "R:mailto:organizer2@example.net"
                 }, {
                     attendee: "ATTENDEE;CN=Attendee;PARTSTAT=NEEDS-ACTION;ROLE=REQ-PARTICIPANT:" +
                               "mailto:attendee@example.net"
-                }, {
-                    dtStamp: "DTSTAMP:20150909T182048Z"
-                }
+                }, { dtStamp: "DTSTAMP:20150909T182048Z" }
             ]
         },
         expected: {
             result: {
                 descr: "Mismatch of uid or organizer in counterproposal.",
                 type: "ERROR"
             },
             differences: []
         }
     }, {
         // #8:counterproposal without any difference
         input: {
             existing: [],
-            proposed: [{ method: "METHOD:COUNTER" }] },
+            proposed: [{ method: "METHOD:COUNTER" }]
+        },
         expected: {
             result: {
                 descr: "No difference in counterproposal detected.",
                 type: "NODIFF"
             },
             differences: []
         }
     }];
@@ -1056,17 +1001,17 @@ add_task(function* parseCounter_test() {
                     modifyProperty(/(UID.+)/, aProp.uid, true);
                 }
             });
         }
         item = item.join("\r\n");
         return createEventFromIcalString(item);
     };
 
-    let formatDt = function (aDateTime) {
+    let formatDt = function(aDateTime) {
         let datetime = cal.getDateFormatter().formatDateTime(aDateTime);
         return datetime += " " + aDateTime.timezone.displayName;
     };
 
     for (let i = 1; i <= data.length; i++) {
         let test = data[i - 1];
         let existingItem = getItem(test.input.existing);
         let proposedItem = getItem(test.input.proposed);
@@ -1081,17 +1026,17 @@ add_task(function* parseCounter_test() {
             let expected = test.expected.differences.filter(bDiff => bDiff.property == aDiff.property);
             if (expected.length == 1) {
                 if (["DTSTART", "DTEND"].includes(aDiff.property)) {
                     let prop = aDiff.proposed ? formatDt(aDiff.proposed) : null;
                     ok(
                         prop && expected[0].proposed.includes(prop),
                         "(test #" + i + ": difference " + aDiff.property + ": proposed '" + prop + "')"
                     );
-                    prop = aDiff.original ? formatDt(aDiff.original) : null
+                    prop = aDiff.original ? formatDt(aDiff.original) : null;
                     ok(
                         prop && expected[0].original.includes(prop),
                         "(test #" + i + ": difference " + aDiff.property + ": original '" + prop + "')"
                     );
                 } else {
                     equal(
                         aDiff.proposed,
                         expected[0].proposed,
--- a/calendar/test/unit/test_recur.js
+++ b/calendar/test/unit/test_recur.js
@@ -82,38 +82,38 @@ function test_rules() {
     }
 
     // Test specific items/rules
     check_recur(makeEvent("DESCRIPTION:Repeat every tuesday and wednesday starting " +
                                      "Tue 2nd April 2002\n" +
                          "RRULE:FREQ=WEEKLY;INTERVAL=1;COUNT=6;BYDAY=TU,WE\n" +
                          "DTSTART:20020402T114500\n" +
                          "DTEND:20020402T124500\n"),
-                         ["20020402T114500", "20020403T114500", "20020409T114500",
-                          "20020410T114500", "20020416T114500", "20020417T114500"]);
+        ["20020402T114500", "20020403T114500", "20020409T114500",
+            "20020410T114500", "20020416T114500", "20020417T114500"]);
     check_recur(makeEvent("DESCRIPTION:Repeat every thursday starting Tue 2nd April 2002\n" +
                          "RRULE:FREQ=WEEKLY;INTERVAL=1;COUNT=6;BYDAY=TH\n" +
                          "DTSTART:20020402T114500\n" +
                          "DTEND:20020402T124500\n"),
-                         ["20020402T114500", // DTSTART part of the resulting set
-                          "20020404T114500", "20020411T114500", "20020418T114500",
-                          "20020425T114500", "20020502T114500", "20020509T114500"]);
+        ["20020402T114500", // DTSTART part of the resulting set
+            "20020404T114500", "20020411T114500", "20020418T114500",
+            "20020425T114500", "20020502T114500", "20020509T114500"]);
     // Bug 469840 -  Recurring Sundays incorrect
     check_recur(makeEvent("DESCRIPTION:RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=6;BYDAY=WE,SA,SU with DTSTART:20081217T133000\n" +
                          "RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=6;BYDAY=WE,SA,SU\n" +
                          "DTSTART:20081217T133000\n" +
                          "DTEND:20081217T143000\n"),
-               ["20081217T133000", "20081220T133000", "20081221T133000",
-                "20081231T133000", "20090103T133000", "20090104T133000"]);
+        ["20081217T133000", "20081220T133000", "20081221T133000",
+            "20081231T133000", "20090103T133000", "20090104T133000"]);
     check_recur(makeEvent("DESCRIPTION:RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=6;WKST=SU;BYDAY=WE,SA,SU with DTSTART:20081217T133000\n" +
                          "RRULE:FREQ=WEEKLY;INTERVAL=2;COUNT=6;WKST=SU;BYDAY=WE,SA,SU\n" +
                          "DTSTART:20081217T133000\n" +
                          "DTEND:20081217T143000\n"),
-               ["20081217T133000", "20081220T133000", "20081228T133000",
-                "20081231T133000", "20090103T133000", "20090111T133000"]);
+        ["20081217T133000", "20081220T133000", "20081228T133000",
+            "20081231T133000", "20090103T133000", "20090111T133000"]);
 
     // bug 353797: occurrences for repeating all day events should stay "all-day"
     check_recur(makeEvent("DESCRIPTION:Allday repeat every thursday starting Tue 2nd April 2002\n" +
                          "RRULE:FREQ=WEEKLY;INTERVAL=1;COUNT=3;BYDAY=TH\n" +
                          "DTSTART;VALUE=DATE:20020404\n" +
                          "DTEND;VALUE=DATE:20020405\n"),
                          ["20020404", "20020411", "20020418"]);
 
@@ -125,26 +125,26 @@ function test_rules() {
                           "20000515T090000", "20010514T090000", "20020513T090000"]);
     */
 
     // bug 899326: Recurrences with BYMONTHDAY=X,X,31 don't show at all in months with less than 31 days
     check_recur(makeEvent("DESCRIPTION:Every 11th & 31st of every Month\n" +
                 "RRULE:FREQ=MONTHLY;COUNT=6;BYMONTHDAY=11,31\n" +
                 "DTSTART:20130731T160000\n" +
                 "DTEND:20130731T170000)\n"),
-                ["20130731T160000", "20130811T160000", "20130831T160000",
-                 "20130911T160000", "20131011T160000", "20131031T160000"]);
+        ["20130731T160000", "20130811T160000", "20130831T160000",
+            "20130911T160000", "20131011T160000", "20131031T160000"]);
 
     // bug 899770: Monthly Recurrences with BYDAY and BYMONTHDAY with more than 2 dates are not working
     check_recur(makeEvent("DESCRIPTION:Every WE & SA the 6th, 20th & 31st\n" +
                 "RRULE:FREQ=MONTHLY;COUNT=6;BYDAY=WE,SA;BYMONTHDAY=6,20,31\n" +
                 "DTSTART:20130706T160000\n" +
                 "DTEND:20130706T170000)\n"),
-                ["20130706T160000", "20130720T160000", "20130731T160000",
-                 "20130831T160000", "20131106T160000", "20131120T160000"]);
+        ["20130706T160000", "20130720T160000", "20130731T160000",
+            "20130831T160000", "20131106T160000", "20131120T160000"]);
 
     check_recur(makeEvent("DESCRIPTION:Every day, use exdate to exclude the second day\n" +
                          "RRULE:FREQ=DAILY;COUNT=3\n" +
                          "DTSTART:20020402T114500Z\n" +
                          "EXDATE:20020403T114500Z\n"),
                          ["20020402T114500Z", "20020404T114500Z"]);
 
     // test for issue 734245
@@ -191,18 +191,18 @@ function test_rules() {
                true /* ignore next occ check, bug 455490 */);
 
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Repeat Daily on weekdays with UNTIL\n" +
                                          "RRULE:FREQ=DAILY;UNTIL=20111217T220000Z;BYDAY=MO,TU,WE,TH,FR\n" +
                                          "DTSTART:20111212T220000Z\n" +
                                          "DTEND:20111212T230000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20111212T220000Z", "20111213T220000Z", "20111214T220000Z", "20111215T220000Z",
-                "20111216T220000Z"],
+        ["20111212T220000Z", "20111213T220000Z", "20111214T220000Z", "20111215T220000Z",
+            "20111216T220000Z"],
                false);
 
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Repeat Daily on weekdays with UNTIL and exception\n" +
                                          "RRULE:FREQ=DAILY;UNTIL=20111217T220000Z;BYDAY=MO,TU,WE,TH,FR\n" +
                                          "EXDATE:20111214T220000Z\n" +
                                          "DTSTART:20111212T220000Z\n" +
                                          "DTEND:20111212T230000Z\n" +
@@ -212,45 +212,45 @@ function test_rules() {
 
     // Bug 958978: Yearly recurrence, the last day of a specified month.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                           "DESCRIPTION:Repeat Yearly the last day of February\n" +
                                           "RRULE:FREQ=YEARLY;COUNT=6;BYMONTHDAY=-1;BYMONTH=2\n" +
                                           "DTSTART:20140228T220000Z\n" +
                                           "DTEND:20140228T230000Z\n" +
                                           "END:VEVENT\nEND:VCALENDAR\n"),
-                ["20140228T220000Z", "20150228T220000Z", "20160229T220000Z",
-                 "20170228T220000Z", "20180228T220000Z", "20190228T220000Z"],
+        ["20140228T220000Z", "20150228T220000Z", "20160229T220000Z",
+            "20170228T220000Z", "20180228T220000Z", "20190228T220000Z"],
                 false);
 
     // Bug 958978: Yearly recurrence, the last day of a not specified month.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                           "DESCRIPTION:Repeat Yearly the last day of April without BYMONTH=4 in the rule\n" +
                                           "RRULE:FREQ=YEARLY;COUNT=6;BYMONTHDAY=-1\n" +
                                           "DTSTART:20140430T220000Z\n" +
                                           "DTEND:20140430T230000Z\n" +
                                           "END:VEVENT\nEND:VCALENDAR\n"),
-                ["20140430T220000Z", "20150430T220000Z", "20160430T220000Z",
-                 "20170430T220000Z", "20180430T220000Z", "20190430T220000Z"],
+        ["20140430T220000Z", "20150430T220000Z", "20160430T220000Z",
+            "20170430T220000Z", "20180430T220000Z", "20190430T220000Z"],
                 false);
 
     // Bug 958978 - Check a yearly recurrence on every WE and FR of January and March
     //              (more BYMONTH and more BYDAY).
     // Check for the occurrences in the first year.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Repeat Yearly every WE and FR of January and March (more BYMONTH and more BYDAY)\n" +
                                          "RRULE:FREQ=YEARLY;COUNT=18;BYMONTH=1,3;BYDAY=WE,FR\n" +
                                          "DTSTART:20140101T150000Z\n" +
                                          "DTEND:20140101T160000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20140101T150000Z", "20140103T150000Z", "20140108T150000Z", "20140110T150000Z",
-                "20140115T150000Z", "20140117T150000Z", "20140122T150000Z", "20140124T150000Z",
-                "20140129T150000Z", "20140131T150000Z",
-                "20140305T150000Z", "20140307T150000Z", "20140312T150000Z", "20140314T150000Z",
-                "20140319T150000Z", "20140321T150000Z", "20140326T150000Z", "20140328T150000Z"],
+        ["20140101T150000Z", "20140103T150000Z", "20140108T150000Z", "20140110T150000Z",
+            "20140115T150000Z", "20140117T150000Z", "20140122T150000Z", "20140124T150000Z",
+            "20140129T150000Z", "20140131T150000Z",
+            "20140305T150000Z", "20140307T150000Z", "20140312T150000Z", "20140314T150000Z",
+            "20140319T150000Z", "20140321T150000Z", "20140326T150000Z", "20140328T150000Z"],
                false);
 
     // Bug 958978 - Check a yearly recurrence every day of January (BYMONTH and more BYDAY).
     // Check for all the occurrences in the first year.
     let expectedDates = [];
     for (let i = 1; i < 32; i++) {
         expectedDates.push("201401" + (i < 10 ? "0" + i : i) + "T150000Z");
     }
@@ -266,111 +266,111 @@ function test_rules() {
     // Bug 958974 - Monthly recurrence every WE, FR and the third MO (monthly with more bydays).
     // Check the occurrences in the first month until the week with the first monday of the rule.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Repeat Monthly every Wednesday, Friday and the third Monday\n" +
                                          "RRULE:FREQ=MONTHLY;COUNT=8;BYDAY=3MO,WE,FR\n" +
                                          "DTSTART:20150102T080000Z\n" +
                                          "DTEND:20150102T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150102T080000Z", "20150107T080000Z", "20150109T080000Z",
-                "20150114T080000Z", "20150116T080000Z", "20150119T080000Z",
-                "20150121T080000Z", "20150123T080000Z"],
+        ["20150102T080000Z", "20150107T080000Z", "20150109T080000Z",
+            "20150114T080000Z", "20150116T080000Z", "20150119T080000Z",
+            "20150121T080000Z", "20150123T080000Z"],
                false);
 
     // Bug 419490 - Monthly recurrence, the fifth Saturday starting from February.
     // Check a monthly rule that specifies a day that is not part of the month
     // the events starts in.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Repeat Monthly the fifth Saturday\n" +
                                          "RRULE:FREQ=MONTHLY;COUNT=6;BYDAY=5SA\n" +
                                          "DTSTART:20150202T080000Z\n" +
                                          "DTEND:20150202T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150202T080000Z",
-                "20150530T080000Z", "20150829T080000Z", "20151031T080000Z",
-                "20160130T080000Z", "20160430T080000Z", "20160730T080000Z"],
+        ["20150202T080000Z",
+            "20150530T080000Z", "20150829T080000Z", "20151031T080000Z",
+            "20160130T080000Z", "20160430T080000Z", "20160730T080000Z"],
                false);
 
     // Bug 419490 - Monthly recurrence, the fifth Wednesday every two months starting from February.
     // Check a monthly rule that specifies a day that is not part of the month
     // the events starts in.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Repeat Monthly the fifth Friday every two months\n" +
                                          "RRULE:FREQ=MONTHLY;INTERVAL=2;COUNT=6;BYDAY=5FR\n" +
                                          "DTSTART:20150202T080000Z\n" +
                                          "DTEND:20150202T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150202T080000Z",
-                "20151030T080000Z", "20160429T080000Z", "20161230T080000Z",
-                "20170630T080000Z", "20171229T080000Z", "20180629T080000Z"],
+        ["20150202T080000Z",
+            "20151030T080000Z", "20160429T080000Z", "20161230T080000Z",
+            "20170630T080000Z", "20171229T080000Z", "20180629T080000Z"],
                false);
 
     // Bugs 419490, 958974 - Monthly recurrence, the 2nd Monday, 5th Wednesday and the 5th to last Saturday every month starting from February.
     // Check a monthly rule that specifies a day that is not part of the month
     // the events starts in with positive and negative position along with other byday.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Repeat Monthly the 2nd Monday, 5th Wednesday and the 5th to last Saturday every month\n" +
                                          "RRULE:FREQ=MONTHLY;COUNT=7;BYDAY=2MO,-5WE,5SA\n" +
                                          "DTSTART:20150401T080000Z\n" +
                                          "DTEND:20150401T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150401T080000Z",
-                "20150413T080000Z", "20150511T080000Z", "20150530T080000Z",
-                "20150608T080000Z", "20150701T080000Z", "20150713T080000Z"],
+        ["20150401T080000Z",
+            "20150413T080000Z", "20150511T080000Z", "20150530T080000Z",
+            "20150608T080000Z", "20150701T080000Z", "20150713T080000Z"],
                false);
 
     // Bug 1146500 - Monthly recurrence, every MO and FR when are odd days starting from the 1st of March.
     // Check the first occurrence when we have BYDAY along with BYMONTHDAY.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Monthly recurrence, every MO and FR when are odd days starting from the 1st of March\n" +
                                          "RRULE:FREQ=MONTHLY;BYDAY=MO,FR;BYMONTHDAY=1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31;COUNT=4\n" +
                                          "DTSTART:20150301T080000Z\n" +
                                          "DTEND:20150301T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150301T080000Z",
-                "20150309T080000Z", "20150313T080000Z", "20150323T080000Z", "20150327T080000Z"],
+        ["20150301T080000Z",
+            "20150309T080000Z", "20150313T080000Z", "20150323T080000Z", "20150327T080000Z"],
                false);
 
     // Bug 1146500 - Monthly recurrence, every MO and FR when are odd days starting from the 1st of April.
     // Check the first occurrence when we have BYDAY along with BYMONTHDAY.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Monthly recurrence, every MO and FR when are odd days starting from the 1st of March\n" +
                                          "RRULE:FREQ=MONTHLY;BYDAY=MO,FR;BYMONTHDAY=1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31;COUNT=4\n" +
                                          "DTSTART:20150401T080000Z\n" +
                                          "DTEND:20150401T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150401T080000Z",
-                "20150403T080000Z", "20150413T080000Z", "20150417T080000Z", "20150427T080000Z"],
+        ["20150401T080000Z",
+            "20150403T080000Z", "20150413T080000Z", "20150417T080000Z", "20150427T080000Z"],
                false);
 
     // Bug 1146500 - Monthly recurrence, every MO and FR when are odd days starting from the 1st of April.
     // Check the first occurrence when we have BYDAY along with BYMONTHDAY.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Monthly recurrence, every MO and FR when are odd days starting from the 1st of March\n" +
                                          "RRULE:FREQ=MONTHLY;BYDAY=MO,SA;BYMONTHDAY=1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31;COUNT=4\n" +
                                          "DTSTART:20150401T080000Z\n" +
                                          "DTEND:20150401T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150401T080000Z",
-                "20150411T080000Z", "20150413T080000Z", "20150425T080000Z", "20150427T080000Z"],
+        ["20150401T080000Z",
+            "20150411T080000Z", "20150413T080000Z", "20150425T080000Z", "20150427T080000Z"],
                false);
 
     // Bug 1146500 - Monthly every SU and FR when are odd days starting from 28 of February (BYDAY and BYMONTHDAY).
     // Check the first occurrence when we have BYDAY along with BYMONTHDAY.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                          "DESCRIPTION:Monthly recurrence, every SU and FR when are odd days starting from the 1st of March\n" +
                                          "RRULE:FREQ=MONTHLY;BYDAY=SU,FR;BYMONTHDAY=1,3,5,7,9,11,13,15,17,19,21,23,25,27,29,31;COUNT=9\n" +
                                          "DTSTART:20150228T080000Z\n" +
                                          "DTEND:20150228T090000Z\n" +
                                          "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20150228T080000Z",
-                "20150301T080000Z", "20150313T080000Z", "20150315T080000Z", "20150327T080000Z",
-                "20150329T080000Z", "20150403T080000Z", "20150405T080000Z", "20150417T080000Z",
-                "20150419T080000Z"],
+        ["20150228T080000Z",
+            "20150301T080000Z", "20150313T080000Z", "20150315T080000Z", "20150327T080000Z",
+            "20150329T080000Z", "20150403T080000Z", "20150405T080000Z", "20150417T080000Z",
+            "20150419T080000Z"],
                false);
 
     // Bug 1103187 - Monthly recurrence with only MONTHLY tag in the rule. Recurrence day taken
     // from the start date. Check four occurrences.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                           "DESCRIPTION:Only Monthly recurrence\n" +
                                           "RRULE:FREQ=MONTHLY;COUNT=4\n" +
                                           "DTSTART:20160404T080000Z\n" +
@@ -382,30 +382,30 @@ function test_rules() {
     // Bug 1265554 - Monthly recurrence with only MONTHLY tag in the rule. Recurrence on the 31st
     // of the month. Check for 6 occurrences.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                           "DESCRIPTION:Only Monthly recurrence, the 31st\n" +
                                           "RRULE:FREQ=MONTHLY;COUNT=6\n" +
                                           "DTSTART:20160131T150000Z\n" +
                                           "DTEND:20160131T160000Z\n" +
                                           "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20160131T150000Z", "20160331T150000Z", "20160531T150000Z",
-                "20160731T150000Z", "20160831T150000Z", "20161031T150000Z"],
+        ["20160131T150000Z", "20160331T150000Z", "20160531T150000Z",
+            "20160731T150000Z", "20160831T150000Z", "20161031T150000Z"],
                false);
 
     // Bug 1265554 - Monthly recurrence with only MONTHLY tag in the rule. Recurrence on the 31st
     // of the month every two months. Check for 6 occurrences.
     check_recur(createEventFromIcalString("BEGIN:VCALENDAR\nBEGIN:VEVENT\n" +
                                           "DESCRIPTION:Only Monthly recurrence, the 31st every 2 months\n" +
                                           "RRULE:FREQ=MONTHLY;INTERVAL=2;COUNT=6\n" +
                                           "DTSTART:20151231T150000Z\n" +
                                           "DTEND:20151231T160000Z\n" +
                                           "END:VEVENT\nEND:VCALENDAR\n"),
-               ["20151231T150000Z", "20160831T150000Z", "20161031T150000Z",
-                "20161231T150000Z", "20170831T150000Z", "20171031T150000Z"],
+        ["20151231T150000Z", "20160831T150000Z", "20161031T150000Z",
+            "20161231T150000Z", "20170831T150000Z", "20171031T150000Z"],
                false);
 
     let item, occ1;
     item = makeEvent("DESCRIPTION:occurrence on day 1 moved between the occurrences " +
                                      "on days 2 and 3\n" +
                          "RRULE:FREQ=DAILY;COUNT=3\n" +
                          "DTSTART:20020402T114500Z\n");
     occ1 = item.recurrenceInfo.getOccurrenceFor(createDate(2002, 3, 2, true, 11, 45, 0));
--- a/calendar/test/unit/test_storage.js
+++ b/calendar/test/unit/test_storage.js
@@ -4,25 +4,25 @@
 
 function run_test() {
     do_calendar_startup(testAttachRoundtrip);
 }
 
 function testAttachRoundtrip() {
     let storage = getStorageCal();
     let str = ["BEGIN:VEVENT",
-               "UID:attachItem",
-               "DTSTART:20120101T010101Z",
-               "ATTACH;FMTTYPE=text/calendar;ENCODING=BASE64;FILENAME=test.ics:http://example.com/test.ics",
-               "ATTENDEE;RSVP=TRUE;CUTYPE=INDIVIDUAL;CN=Name;PARTSTAT=ACCEPTED;ROLE=REQ-PARTICIPANT;X-THING=BAR:mailto:test@example.com",
-               "RELATED-TO;RELTYPE=SIBLING;FOO=BAR:VALUE",
-               "RRULE:FREQ=MONTHLY;INTERVAL=2;COUNT=5;BYDAY=MO",
-               "RDATE:20120201T010101Z",
-               "EXDATE:20120301T010101Z",
-               "END:VEVENT"].join("\r\n");
+        "UID:attachItem",
+        "DTSTART:20120101T010101Z",
+        "ATTACH;FMTTYPE=text/calendar;ENCODING=BASE64;FILENAME=test.ics:http://example.com/test.ics",
+        "ATTENDEE;RSVP=TRUE;CUTYPE=INDIVIDUAL;CN=Name;PARTSTAT=ACCEPTED;ROLE=REQ-PARTICIPANT;X-THING=BAR:mailto:test@example.com",
+        "RELATED-TO;RELTYPE=SIBLING;FOO=BAR:VALUE",
+        "RRULE:FREQ=MONTHLY;INTERVAL=2;COUNT=5;BYDAY=MO",
+        "RDATE:20120201T010101Z",
+        "EXDATE:20120301T010101Z",
+        "END:VEVENT"].join("\r\n");
 
     let storageItem = createEventFromIcalString(str);
 
     do_test_pending();
     storage.addItem(storageItem, {
         onOperationComplete: function(calendar, status, opType, id, addedItem) {
             do_execute_soon(() => {
                 // Make sure the cache is cleared, otherwise we'll get the cached item.
--- a/calendar/test/unit/test_timezone.js
+++ b/calendar/test/unit/test_timezone.js
@@ -12,68 +12,68 @@ function run_test() {
     });
 }
 
 function really_run_test() {
     let event = cal.createEvent();
 
     let str =
          ["BEGIN:VCALENDAR",
-          "PRODID:-//RDU Software//NONSGML HandCal//EN",
-          "VERSION:2.0",
-          "BEGIN:VTIMEZONE",
-          "TZID:America/New_York",
-          "BEGIN:STANDARD",
-          "DTSTART:19981025T020000",
-          "TZOFFSETFROM:-0400",
-          "TZOFFSETTO:-0500",
-          "TZNAME:EST",
-          "END:STANDARD",
-          "BEGIN:DAYLIGHT",
-          "DTSTART:19990404T020000",
-          "TZOFFSETFROM:-0500",
-          "TZOFFSETTO:-0400",
-          "TZNAME:EDT",
-          "END:DAYLIGHT",
-          "END:VTIMEZONE",
-          "BEGIN:VEVENT",
-          "DTSTAMP:19980309T231000Z",
-          "UID:guid-1.example.com",
-          "ORGANIZER:mailto:mrbig@example.com",
-          "ATTENDEE;RSVP=TRUE;ROLE=REQ-PARTICIPANT;CUTYPE=GROUP:",
-          " mailto:employee-A@example.com",
-          "DESCRIPTION:Project XYZ Review Meeting",
-          "CATEGORIES:MEETING",
-          "CLASS:PUBLIC",
-          "CREATED:19980309T130000Z",
-          "SUMMARY:XYZ Project Review",
-          "DTSTART;TZID=America/New_York:19980312T083000",
-          "DTEND;TZID=America/New_York:19980312T093000",
-          "LOCATION:1CP Conference Room 4350",
-          "END:VEVENT",
-          "END:VCALENDAR",
-          ""].join("\r\n");
+             "PRODID:-//RDU Software//NONSGML HandCal//EN",
+             "VERSION:2.0",
+             "BEGIN:VTIMEZONE",
+             "TZID:America/New_York",
+             "BEGIN:STANDARD",
+             "DTSTART:19981025T020000",
+             "TZOFFSETFROM:-0400",
+             "TZOFFSETTO:-0500",
+             "TZNAME:EST",
+             "END:STANDARD",
+             "BEGIN:DAYLIGHT",
+             "DTSTART:19990404T020000",
+             "TZOFFSETFROM:-0500",
+             "TZOFFSETTO:-0400",
+             "TZNAME:EDT",
+             "END:DAYLIGHT",
+             "END:VTIMEZONE",
+             "BEGIN:VEVENT",
+             "DTSTAMP:19980309T231000Z",
+             "UID:guid-1.example.com",
+             "ORGANIZER:mailto:mrbig@example.com",
+             "ATTENDEE;RSVP=TRUE;ROLE=REQ-PARTICIPANT;CUTYPE=GROUP:",
+             " mailto:employee-A@example.com",
+             "DESCRIPTION:Project XYZ Review Meeting",
+             "CATEGORIES:MEETING",
+             "CLASS:PUBLIC",
+             "CREATED:19980309T130000Z",
+             "SUMMARY:XYZ Project Review",
+             "DTSTART;TZID=America/New_York:19980312T083000",
+             "DTEND;TZID=America/New_York:19980312T093000",
+             "LOCATION:1CP Conference Room 4350",
+             "END:VEVENT",
+             "END:VCALENDAR",
+             ""].join("\r\n");
 
     let strTz =
          ["BEGIN:VTIMEZONE",
-          "TZID:America/New_York",
-          "BEGIN:STANDARD",
-          "DTSTART:19981025T020000",
-          "TZOFFSETFROM:-0400",
-          "TZOFFSETTO:-0500",
-          "TZNAME:EST",
-          "END:STANDARD",
-          "BEGIN:DAYLIGHT",
-          "DTSTART:19990404T020000",
-          "TZOFFSETFROM:-0500",
-          "TZOFFSETTO:-0400",
-          "TZNAME:EDT",
-          "END:DAYLIGHT",
-          "END:VTIMEZONE",
-          ""].join("\r\n");
+             "TZID:America/New_York",
+             "BEGIN:STANDARD",
+             "DTSTART:19981025T020000",
+             "TZOFFSETFROM:-0400",
+             "TZOFFSETTO:-0500",
+             "TZNAME:EST",
+             "END:STANDARD",
+             "BEGIN:DAYLIGHT",
+             "DTSTART:19990404T020000",
+             "TZOFFSETFROM:-0500",
+             "TZOFFSETTO:-0400",
+             "TZNAME:EDT",
+             "END:DAYLIGHT",
+             "END:VTIMEZONE",
+             ""].join("\r\n");
 
     let tzs = cal.getTimezoneService();
 
     event.icalString = str;
 
     let startDate = event.startDate;
     let endDate = event.endDate;