Skip to content

Commit

Permalink
cleanup: code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
dafuga committed Sep 13, 2024
1 parent 774e6ef commit cc23341
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/components/chart/rampricehistory.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
let dataRange = $derived.by(() => {
if (!data || data.length === 0) return [];
const rangeEndDate = dayjs(data[0].date);
const rangeStartDate = rangeEndDate.subtract(Number(selectedRange.value), 'day');
const rangeStartDate = rangeEndDate.subtract(selectedRange.value, 'day');
debug && $inspect({ rangeStartDate, rangeEndDate });
return data.filter(({ date }) => dayjs(date).isAfter(rangeStartDate));
});
Expand Down

0 comments on commit cc23341

Please sign in to comment.