From 982fbd36781f5f937f9ee0ba1fbbd8b851c23501 Mon Sep 17 00:00:00 2001 From: Henry Catalini Smith Date: Wed, 17 Jul 2024 22:08:23 +0200 Subject: [PATCH] Replace 000Z suffix with dayjs.utc call --- src/features/tasks/utils/getTaskStatus.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/features/tasks/utils/getTaskStatus.ts b/src/features/tasks/utils/getTaskStatus.ts index 6ae6591199..8bfee82655 100644 --- a/src/features/tasks/utils/getTaskStatus.ts +++ b/src/features/tasks/utils/getTaskStatus.ts @@ -20,8 +20,7 @@ const getTaskStatus = (task: ZetkinTask): TASK_STATUS => { return TASK_STATUS.EXPIRED; } - const isPublishedPassed = - published && dayjs(published + '.000Z').isBefore(now); + const isPublishedPassed = published && dayjs.utc(published).isBefore(now); if (isPublishedPassed) { return TASK_STATUS.ACTIVE;