Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/cog_presentation/cog.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
import cog_presentation.info
from cog_presentation import strings
from cog_presentation import settings
from urpy.utils import error_log
from urpy.utils import error_log, colored_message, SUCCESS_COLOR, ERROR_COLOR
import pickle
import os
from pathlib import Path
Expand Down Expand Up @@ -45,7 +45,7 @@ async def prez(self, ctx):
# TODO fix contexts shenanigans
# checks that $cal is called in the right place
if isinstance(ctx.channel, discord.DMChannel):
await base_ctx.send(_(strings.on_prez_dm_channel))
await base_ctx.send(colored_message(_(strings.on_prez_dm_channel), ERROR_COLOR))
elif isinstance(ctx.channel, discord.TextChannel):
anncmnt_channel = discord.utils.get(ctx.guild.channels, name=settings.announcement_channel)
if not anncmnt_channel:
Expand Down Expand Up @@ -78,11 +78,11 @@ async def prez(self, ctx):
except discord.errors.Forbidden:
error_log("Impossible d'obtenir les webhooks.", # TODO change to english
"Le bot nécessite la permission de gérer les webhooks")
await ctx.author.send(strings.on_permission_error)
await ctx.author.send(colored_message(strings.on_permission_error, ERROR_COLOR))
except IndexError:
await ctx.send(_(strings.on_prez_webhook_not_found.format(channel=settings.announcement_channel)))
else:
await ctx.send(_(strings.on_prez))
await ctx.send(colored_message(_(strings.on_prez), SUCCESS_COLOR))
await ctx.author.send(
strings.on_prez_link.format(link=f"http://presentation.unionrolistes.fr"))
#?webhook={webhook.url}"))
Expand Down
3 changes: 2 additions & 1 deletion src/cog_presentation/info/credits.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
Lyss <delpratflo@cy-tech.fr>
Maestro#8364 <yoyou20@hotmail.fr>
Maestro#8364 <yoyou20@hotmail.fr>
Mortifia
Loading