mirror of
https://github.com/bitbaum/loki.git
synced 2026-12-04 16:27:37 +01:00
The 7-line streak loop appeared twice — once using HABIT_HISTORY_DAYS as the bound (listHabitsForToday) and once using a dynamic days param (getHabitHeatmapData). Extracted to a private computeStreak(dates, maxDays) function eliminating the duplication. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>