mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-21 18:27:59 -05:00
Normalize names of attributes with Config instances (#3765)
* Lets normalize how we name config attributes across the bot. Signed-off-by: Drapersniper <27962761+drapersniper@users.noreply.github.com> * .... Signed-off-by: Drapersniper <27962761+drapersniper@users.noreply.github.com> * nothing to see here Signed-off-by: Drapersniper <27962761+drapersniper@users.noreply.github.com>
This commit is contained in:
@@ -14,8 +14,7 @@ class SelfRole(commands.Converter):
|
||||
role_converter = commands.RoleConverter()
|
||||
role = await role_converter.convert(ctx, arg)
|
||||
|
||||
conf = admin.conf
|
||||
selfroles = await conf.guild(ctx.guild).selfroles()
|
||||
selfroles = await admin.config.guild(ctx.guild).selfroles()
|
||||
|
||||
if role.id not in selfroles:
|
||||
raise commands.BadArgument(_("The provided role is not a valid selfrole."))
|
||||
|
||||
Reference in New Issue
Block a user