From 174da38cc8f2958201a58ed0bc567c6ccfc54dd4 Mon Sep 17 00:00:00 2001 From: Sam Detweiler Date: Mon, 5 Sep 2022 15:02:16 -0500 Subject: [PATCH] run prettier --- CHANGELOG.md | 2 +- modules/default/calendar/calendarutils.js | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 2fc7cfa9..873311aa 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -28,7 +28,7 @@ _This release is scheduled to be released on 2022-10-01._ - Respect rss ttl provided by newsfeed (#2883). - Fix multi day calendar events always presented as "(1/X)" instead of the amount of days the event has progressed. - Fix weatherbit provider to use type config value instead of endpoint -- Fix calendar events which DO NOT specify rrule byday adjusted incorrectly #2885 +- Fix calendar events which DO NOT specify rrule byday adjusted incorrectly #2885 ## [2.20.0] - 2022-07-02 diff --git a/modules/default/calendar/calendarutils.js b/modules/default/calendar/calendarutils.js index 1ac4eb54..dc4b5c92 100644 --- a/modules/default/calendar/calendarutils.js +++ b/modules/default/calendar/calendarutils.js @@ -333,9 +333,9 @@ const CalendarUtils = { // If the offset is negative (east of GMT), where the problem is if (dateoffset < 0) { if (dh < Math.abs(dateoffset / 60)) { - // if the rrule byweekday WAS explicitly set , correct it + // if the rrule byweekday WAS explicitly set , correct it // reduce the time by the offset - if(curEvent.rrule.origOptions.byweekday !== undefined){ + if (curEvent.rrule.origOptions.byweekday !== undefined) { // Apply the correction to the date/time to get it UTC relative date = new Date(date.getTime() - Math.abs(24 * 60) * 60000); } @@ -350,8 +350,8 @@ const CalendarUtils = { // if the date hour is less than the offset if (24 - dh <= Math.abs(dateoffset / 60)) { // if the rrule byweekday WAS explicitly set , correct it - if(curEvent.rrule.origOptions.byweekday !== undefined){ - if(curEvent.rrule.origOptions.byweekday !== undefined){ + if (curEvent.rrule.origOptions.byweekday !== undefined) { + if (curEvent.rrule.origOptions.byweekday !== undefined) { // apply the correction to the date/time back to right day date = new Date(date.getTime() + Math.abs(24 * 60) * 60000); } @@ -370,7 +370,7 @@ const CalendarUtils = { // if the date hour is less than the offset if (dh <= Math.abs(dateoffset / 60)) { // if the rrule byweekday WAS explicitly set , correct it - if(curEvent.rrule.origOptions.byweekday !== undefined){ + if (curEvent.rrule.origOptions.byweekday !== undefined) { // Reduce the time by t: // Apply the correction to the date/time to get it UTC relative date = new Date(date.getTime() - Math.abs(24 * 60) * 60000); @@ -386,7 +386,7 @@ const CalendarUtils = { // if the date hour is less than the offset if (24 - dh <= Math.abs(dateoffset / 60)) { // if the rrule byweekday WAS explicitly set , correct it - if(curEvent.rrule.origOptions.byweekday !== undefined){ + if (curEvent.rrule.origOptions.byweekday !== undefined) { // apply the correction to the date/time back to right day date = new Date(date.getTime() + Math.abs(24 * 60) * 60000); }