Skip to content

Commit e205dab

Browse files
authored
fix: hot fix in plan's createdAt
1 parent 6294086 commit e205dab

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

frontend/src/components/PlanItem.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ export const PlanItem = ({
108108
id: uuid,
109109
onlineId,
110110
name,
111+
createdAt: new Date(),
111112
});
112113

113114
setTimeout(() => {
@@ -139,7 +140,9 @@ export const PlanItem = ({
139140
</CardTitle>
140141
<CardDescription>
141142
{format(
142-
onlineOnly ? updatedAt : plan.createdAt,
143+
onlineOnly
144+
? updatedAt
145+
: ((plan.createdAt as Date | undefined) ?? new Date()),
143146
"dd.MM.yyyy - HH:mm",
144147
)}
145148
</CardDescription>

0 commit comments

Comments
 (0)