Skip to content

Commit 62d467f

Browse files
committed
remove quarters variable in commitcountutil
1 parent 1bd46cf commit 62d467f

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/main/kotlin/app/util/CommitCountUtil.kt

+1-2
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,8 @@ object CommitCountUtil {
1717
fun getCommitsForQuarters(user: User, repoCommits: Map<Repository, List<RepositoryCommit>>): SortedMap<String, Int> {
1818
val creation = asInstant(user.createdAt).withDayOfMonth(1)
1919
val now = Instant.now().atOffset(UTC).with(TemporalAdjusters.firstDayOfNextMonth())
20-
val quarters = QUARTER_YEARS.between(creation, now)
2120

22-
val quarterBuckets = (0..quarters)
21+
val quarterBuckets = (0..QUARTER_YEARS.between(creation, now))
2322
.associate { yearQuarterFromDate(creation.plus(it, QUARTER_YEARS)) to 0 }
2423
.toSortedMap()
2524

0 commit comments

Comments
 (0)