clean slate, birthday fix
This commit is contained in:
@@ -50,12 +50,15 @@ module.exports = {
|
||||
{ $inc: { [`stat.${amount}`]: 1 } },
|
||||
{ upsert: true }
|
||||
)
|
||||
let content = `Du hast ${amount} Nüsse bekommen! :chestnut:`
|
||||
if (!amount) {
|
||||
content = `Du hast leider keine Nüsse bekommen :(`
|
||||
// Helper for singular/plural
|
||||
const formatNut = (amount) => `${amount === 1 ? 'eine' : amount} ${amount === 1 ? 'Nuss' : 'Nüsse'}`
|
||||
|
||||
let nutText = `Du hast ${formatNut(amount)} bekommen! :chestnut:`
|
||||
if (amount <= 0) {
|
||||
nutText = `Du hast keine Nuss bekommen! :yoink_help:`
|
||||
}
|
||||
return await message.reply({
|
||||
content: content
|
||||
content: nutText
|
||||
})
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user