Skip to content
This repository was archived by the owner on Mar 23, 2025. It is now read-only.

Commit b83313b

Browse files
committed
Set recently added group range to 1 day
1 parent 62af879 commit b83313b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/library.cr

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -575,7 +575,8 @@ class Library
575575
.sort { |a, b| b.date_added <=> a.date_added }
576576
.each do |e|
577577
last = recently_added.last?
578-
if last && e.title_id == last[:entry].title_id
578+
if last && e.title_id == last[:entry].title_id &&
579+
(e.date_added - last[:entry].date_added).duration < 1.day
579580
# A NamedTuple is immutable, so we have to cast it to a Hash first
580581
last_hash = last.to_h
581582
count = last_hash[:grouped_count].as(Int32)

0 commit comments

Comments
 (0)