fix: use zero time if user has not exported their data before

This commit is contained in:
sam 2023-03-16 16:43:28 +00:00
parent 1843f58d96
commit a1d3431770

View file

@ -12,7 +12,7 @@
const createdAt = data.exportData?.created_at const createdAt = data.exportData?.created_at
? DateTime.fromISO(data.exportData.created_at).toLocal() ? DateTime.fromISO(data.exportData.created_at).toLocal()
: DateTime.now(); : DateTime.fromSeconds(0);
const now = DateTime.now().toLocal(); const now = DateTime.now().toLocal();
const availableFor = Duration.fromObject({ days: 7 }); const availableFor = Duration.fromObject({ days: 7 });