[Solved] Custom status with guild number [closed]


Alright, I am using this in my bot too: here is the code

//...
client.on('ready', () => {
//...
client.user.setActivity('othertext' + client.guilds.cache.size, {type : 'PLAYING'})
}

client.on('guildCreate', guild => {
//same code as 'ready'
})

client.on('guildDelete', guild => {
//also the same code as 'ready'
})

Now this was from my human memory but this is a start, just modify it with any errors you may have, hopefully there are none.
NOTE: If you are just putting the number of guilds, for some reason, make sure the add the ” after the client.guilds.cache.size, otherwise you will get an error saying it got a number but expected string

1

solved Custom status with guild number [closed]