diff --git a/cogs/register/__init__.py b/cogs/register/__init__.py index d8c0b5d..40ee7c8 100644 --- a/cogs/register/__init__.py +++ b/cogs/register/__init__.py @@ -2,11 +2,9 @@ Bot command for registering various channels to the bot. """ -from typing import Optional -from nextcord import Embed, Interaction, Permissions, SlashOption -import nextcord from nextcord.ext import commands +import nextcord from highscores import highscores_data # pylint: disable=import-error @@ -14,10 +12,6 @@ from highscores import highscores_data # pylint: disable=import-error class Register(commands.Cog, name="Register"): """ Class holds various register commands. - - Args: - commands.Cog: Parent class - name (str, optional): Name of Cog. Defaults to "Register". """ def __init__(self) -> None: @@ -25,7 +19,7 @@ class Register(commands.Cog, name="Register"): Default constructor for Register class. Does nothing. """ - @nextcord.slash_command(default_member_permissions=Permissions(administrator=True)) + @nextcord.slash_command(default_member_permissions=nextcord.Permissions(administrator=True)) async def register(self): """ Parent slash command, never called. @@ -35,7 +29,7 @@ class Register(commands.Cog, name="Register"): async def highscore( self, interaction: nextcord.Interaction, - channel: nextcord.abc.GuildChannel = SlashOption( + channel: nextcord.abc.GuildChannel = nextcord.SlashOption( description="Channel to register", required=False, channel_types=[nextcord.ChannelType.text], @@ -62,7 +56,7 @@ class Register(commands.Cog, name="Register"): async def submission( self, interaction: nextcord.Interaction, - channel: nextcord.abc.GuildChannel = SlashOption( + channel: nextcord.abc.GuildChannel = nextcord.SlashOption( description="Channel to register", required=False, channel_types=[nextcord.ChannelType.text], @@ -89,7 +83,7 @@ class Register(commands.Cog, name="Register"): async def verify( self, interaction: nextcord.Interaction, - channel: nextcord.abc.GuildChannel = SlashOption( + channel: nextcord.abc.GuildChannel = nextcord.SlashOption( description="Channel to register", required=False, channel_types=[nextcord.ChannelType.text], diff --git a/highscores.py b/highscores.py index a93b949..45f1ace 100644 --- a/highscores.py +++ b/highscores.py @@ -6,8 +6,8 @@ import logging import os import sys -import nextcord from nextcord.ext import commands +import nextcord import config from classes.highscores_data import HighscoresData