We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3dece57 commit 04baddeCopy full SHA for 04badde
1 file changed
src/utils/firebase.ts
@@ -327,6 +327,7 @@ export const updateStreakStart = async (userId: string, startDate: Date) => {
327
328
await updateDoc(userRef, {
329
streakDays: diffInDays > 0 ? diffInDays : 0, // Ensure streakDays is not negative
330
+ streakStart: Timestamp.fromDate(startDate)
331
});
332
333
return { success: true, message: 'Streak start updated successfully' };
0 commit comments