You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
if(!interaction.isButton())return;//if the interaction isnt a button: return
5
+
if(interaction.customId==='mc-refresh'){//if the interaction id, matches the one of the buttont we mad earlier
6
+
constdata=awaitmcSchema.findOne({UserID: interaction.user.id,Guild: interaction.guild.id});//fetching data from the db
7
+
if(!data){
8
+
returninteraction.reply('You have never used this command before, so no data is here to update it to your last request.')//if no data already exists, your not able to update the button, this can be good for a general used embed. change it if you dont see any need in that feature
9
+
}
10
+
functioninitServerData(serverIp){//same as before, check the command file for documentation
0 commit comments