Capping leaderboard number.
This commit is contained in:
parent
06eb743e32
commit
c3639b15e6
|
@ -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) {
|
||||
|
|
Loading…
Reference in New Issue