From 9c556eb919c5b5ef92996c2007cfcb8e46190b41 Mon Sep 17 00:00:00 2001 From: Venla Date: Fri, 6 Dec 2024 14:19:10 +0200 Subject: [PATCH] fix report page when no active deadline --- client/components/ReportPage/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/components/ReportPage/index.js b/client/components/ReportPage/index.js index bc9820ca..e2654dbc 100644 --- a/client/components/ReportPage/index.js +++ b/client/components/ReportPage/index.js @@ -43,8 +43,8 @@ export default () => { year, tempAnswers: answers, oldAnswers, - draftYear: draftYear && draftYear.year, - deadline: nextDeadline, + draftYear: draftYear?.year ?? new Date().getFullYear(), + deadline: nextDeadline ?? new Date(), form: filters.form, })