feat(arabot): add check so there can only be one leader of a group

This commit is contained in:
smyalygames 2023-03-01 14:16:00 +00:00
parent cd3c209ede
commit 6a96772c25

View File

@ -271,6 +271,11 @@ export class OutreachCommand extends Subcommand {
await interaction.deferReply({ ephemeral: true });
if (await getStatFromLeader(leader.id) !== null) {
await interaction.editReply(`${leader} is already a leader for another group!`);
return;
}
const event = await getCurrentEvent();
if (event === null) {