Created
October 18, 2018 18:56
-
-
Save DeMarko/f2fd61967c91958020f38262d431ca2d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/app_admin/client/lib/holidays.js b/app_admin/client/lib/holidays.js | |
index adae7bfcb..7b586e084 100644 | |
--- a/app_admin/client/lib/holidays.js | |
+++ b/app_admin/client/lib/holidays.js | |
@@ -111,8 +111,10 @@ export const isMidweekHoliday = () => { | |
isHoliday = true; | |
} | |
/* adds 1 day padding to midweek holidays so day before holiday also | |
- triggers holiday delay messaging. */ | |
- if (holiday.subtract(1, 'days').format('LLLL') === today.format('LLLL')) { | |
+ * triggers holiday delay messaging. | |
+ */ | |
+ const dayBeforeHoliday = holiday.clone().subtract(1, 'days'); | |
+ if (dayBeforeHoliday.format('LLLL') === today.format('LLLL')) { | |
isHoliday = true; | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment