diff --git a/cogs/emoji.py b/cogs/emoji.py index b3d7b4a..cbcaa25 100644 --- a/cogs/emoji.py +++ b/cogs/emoji.py @@ -23,7 +23,7 @@ from discord.ext import commands import utils from utils import errors -class Emoji: +class Emotes: def __init__(self, bot): self.bot = bot self.http = aiohttp.ClientSession(loop=self.bot.loop, read_timeout=30, headers={ @@ -209,4 +209,4 @@ class Emoji: def setup(bot): - bot.add_cog(Emoji(bot)) + bot.add_cog(Emotes(bot)) diff --git a/utils/errors.py b/utils/errors.py index 1fa8efb..0ba7f2f 100644 --- a/utils/errors.py +++ b/utils/errors.py @@ -4,37 +4,37 @@ from discord.ext.commands import CommandError -class EmojiManagerError(CommandError): +class EmoteManagerError(CommandError): """Generic error with the bot. This can be used to catch all bot errors.""" pass -class HTTPException(EmojiManagerError): +class HTTPException(EmoteManagerError): """The server did not respond with an OK status code.""" def __init__(self, status): super().__init__(f'URL error: server returned error code {status}') -class EmojiNotFoundError(EmojiManagerError): - """An emoji with that name was not found""" +class EmoteNotFoundError(EmoteManagerError): + """An emote with that name was not found""" def __init__(self, name): - super().__init__(f'An emoji called `{name}` does not exist in this server.') + super().__init__(f'An emote called `{name}` does not exist in this server.') -class InvalidImageError(EmojiManagerError): +class InvalidImageError(EmoteManagerError): """The image is not a GIF, PNG, or JPG""" def __init__(self): super().__init__('The image supplied was not a GIF, PNG, or JPG.') -class NoMoreSlotsError(EmojiManagerError): +class NoMoreSlotsError(EmoteManagerError): """Raised in case all slots of a particular type (static/animated) are full""" def __init__(self): super().__init__('No more backend slots available.') -class PermissionDeniedError(EmojiManagerError): - """Raised when a user tries to modify an emoji without the Manage Emojis permission""" +class PermissionDeniedError(EmoteManagerError): + """Raised when a user tries to modify an emote without the Manage Emojis permission""" def __init__(self, name): super().__init__(f"You're not authorized to modify `{name}`.")