Skip to content

Commit 8bedc02

Browse files
author
Alex L
authored
fix leaderboard array being overflowed, causing coin lb to break (#524)
1 parent 92c6d15 commit 8bedc02

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/commandDetails/coin/leaderboard.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ const getCoinLeaderboardEmbed = async (
3636
leaderboard = await getCoinLeaderboard(LEADERBOARD_LIMIT_FETCH, offset);
3737
i = 0;
3838
}
39-
if (leaderboard.length === 0) {
39+
if (i >= leaderboard.length) {
4040
break;
4141
}
4242
const userCoinEntry = leaderboard[i++];

0 commit comments

Comments
 (0)