From e920eb41fe3d6d0f511889ac02ae2f7c3011b4b2 Mon Sep 17 00:00:00 2001 From: Lucid Kobold Date: Mon, 3 Jan 2022 14:21:40 -0600 Subject: [PATCH] Fixed index for sticker month array. --- contexts/CalenderContext.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contexts/CalenderContext.tsx b/contexts/CalenderContext.tsx index 95a48cf..662c293 100644 --- a/contexts/CalenderContext.tsx +++ b/contexts/CalenderContext.tsx @@ -131,7 +131,7 @@ const CalenderContextProvider = ({ const overflowInfo = isOverflow(selectedDate, sunCurrDate); const stickerDay = overflowInfo.isOverflow ? null - : stickersMonth[getDate(sunCurrDate)]; + : stickersMonth[getDate(sunCurrDate) - 1]; const day: MonthDay = { ...overflowInfo, @@ -169,7 +169,7 @@ const CalenderContextProvider = ({ const overflowInfo = isOverflow(selectedDate, monCurrDate); const stickerDay = overflowInfo.isOverflow ? null - : stickersMonth[getDate(monCurrDate)]; + : stickersMonth[getDate(monCurrDate) - 1]; const day: MonthDay = { ...overflowInfo,