From 3e1e5747e19c605b21288bc0eae524c08934dade Mon Sep 17 00:00:00 2001 From: Minteck Date: Thu, 10 Feb 2022 23:24:11 +0100 Subject: Fix: pony stats not showing --- commands/info.js | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/commands/info.js b/commands/info.js index 10b1f42..ac2846f 100644 --- a/commands/info.js +++ b/commands/info.js @@ -56,11 +56,16 @@ module.exports = async (interaction) => { let statsCommand = "-"; try { statsCommand = Object.keys(statsCommands).reduce((a, b) => statsCommands[a] > statsCommands[b] ? a : b); - } catch (e) {} + } catch (e) { + console.error(e); + } + let statsPony = "-"; try { - Object.keys(statsPonies).reduce((a, b) => statsPonies[a] > statsPonies[b] ? a : b); - } catch (e) {} + statsPony = Object.keys(statsPonies).reduce((a, b) => statsPonies[a] > statsPonies[b] ? a : b); + } catch (e) { + console.error(e); + } let fields = [ { name: l("Software version", "Version du logiciel", interaction.user.id, interaction.guild ? interaction.guild.id : 0), value: "v" + fs.readFileSync("./config/version.txt").toString().trim() + "." + fs.readFileSync("./.git/refs/heads/trunk").toString().substr(0, 8) + suffix + " (#" + client.shard.count + ")", inline: false }, -- cgit