From 7623fd5e0bdfecf19b1c6ce66340e65104f5f48e Mon Sep 17 00:00:00 2001 From: Noikoio Date: Mon, 27 May 2019 22:45:05 -0700 Subject: [PATCH] Add validation against 'everyone' role --- BirthdayBot/UserInterface/ManagerCommands.vb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/BirthdayBot/UserInterface/ManagerCommands.vb b/BirthdayBot/UserInterface/ManagerCommands.vb index 9b886c1..179ba56 100644 --- a/BirthdayBot/UserInterface/ManagerCommands.vb +++ b/BirthdayBot/UserInterface/ManagerCommands.vb @@ -80,6 +80,8 @@ Friend Class ManagerCommands If role Is Nothing Then Await reqChannel.SendMessageAsync(RoleInputError) + ElseIf role.Id = reqChannel.Guild.EveryoneRole.Id Then + Await reqChannel.SendMessageAsync(":x: You cannot set that as the birthday role.") Else SyncLock Instance.KnownGuilds Instance.KnownGuilds(guild.Id).UpdateRoleAsync(role.Id).Wait()