Catch for users who have paid member role

imgbot
kieranrobson 2022-05-13 12:05:12 +01:00
parent ed83daa171
commit e83a060c1f
1 changed files with 27 additions and 19 deletions

View File

@ -43,6 +43,13 @@ client.on("interactionCreate", async (interaction) => {
if(interaction.customId == "paidModal")
{
if(interaction.member.roles.cache.has(`427878753008353292`))
{
await interaction.deferReply({ ephemeral: true })
interaction.followUp({ content: 'You already have the paid member role.', ephemeral: true })
}
else{
const modal = new ModalBuilder() // We create a Modal
.setCustomId('modal-paidmember')
.setTitle('Paid Member Discord Access')
@ -63,6 +70,7 @@ client.on("interactionCreate", async (interaction) => {
)
client.modal.open(interaction, modal)
}
}
if(interaction.customId == "paidmemberdelete")
{