From c3639b15e69c689a502a382a02099e231429c273 Mon Sep 17 00:00:00 2001 From: Niels Simenon Date: Sat, 6 Nov 2021 01:38:06 +0100 Subject: [PATCH] Capping leaderboard number. --- src/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/app.js b/src/app.js index 28a80b6..1b657fd 100644 --- a/src/app.js +++ b/src/app.js @@ -90,7 +90,7 @@ function getLeaderboard(game, { user, room }) { .slice(-10) .join(', '); - game.sendMessage(`The top ${Math.min(Object.keys(curatedLeaderboard).length, 10)} *${game.name}* players are: ${curatedLeaderboard}`, room.id); + game.sendMessage(`The top ${Math.min(Object.keys(leaderboard).length, 10)} *${game.name}* players are: ${curatedLeaderboard}`, room.id); } function onConnect(data, bot) {