Working on #14

This commit is contained in:
kku
2024-12-16 16:25:35 +01:00
parent 41112018da
commit 454ce2b6fb
7 changed files with 62 additions and 50 deletions

View File

@@ -19,7 +19,7 @@ class CustomChannels(commands.Cog):
@commands.Cog.listener()
async def on_guild_channel_delete(self, channel: GuildChannel):
col_users.find_one_and_update(
await col_users.find_one_and_update(
{"customchannel": channel.id}, {"$set": {"customchannel": None}}
)
@@ -77,7 +77,7 @@ class CustomChannels(commands.Cog):
manage_channels=True,
)
holo_user_ctx.set("customchannel", created_channel.id)
await holo_user_ctx.set("customchannel", created_channel.id)
await ctx.respond(
embed=Embed(
@@ -178,7 +178,7 @@ class CustomChannels(commands.Cog):
color=Color.fail,
)
)
holo_user_ctx.set("customchannel", None)
await holo_user_ctx.set("customchannel", None)
return
# Return if the confirmation is missing
@@ -194,7 +194,7 @@ class CustomChannels(commands.Cog):
await custom_channel.delete(reason="Власник запросив видалення")
holo_user_ctx.set("customchannel", None)
await holo_user_ctx.set("customchannel", None)
await ctx.respond(
embed=Embed(