Entire submission process works somehow.

This commit is contained in:
alwayscompiling
2022-07-09 11:24:29 -04:00
parent 6a7207d710
commit 7854be890f
7 changed files with 78 additions and 23 deletions
+4 -4
View File
@@ -1,5 +1,5 @@
"""
Bot command to post the highscores
Cog for creating submission process.
"""
from nextcord.ext import commands
@@ -8,7 +8,7 @@ from .submission_views import SubmissionButton
class SubmissionCog(commands.Cog, name="Submission Cog"):
"""Posts Highscores."""
"""Constructs submission method."""
def __init__(self, bot: commands.Bot):
self.bot = bot
@@ -16,11 +16,11 @@ class SubmissionCog(commands.Cog, name="Submission Cog"):
@commands.Cog.listener()
async def on_ready(self):
"""Called when cog is loaded"""
self.bot.add_view(SubmissionButton())
self.bot.add_view(SubmissionButton(self.bot))
# This function will be called when this extension is loaded.
# It is necessary to add these functions to the bot.
def setup(bot: commands.Bot):
"""Adds functon to bot"""
"""Adds function to bot"""
bot.add_cog(SubmissionCog(bot))