diff --git a/commands/booru.py b/commands/booru.py index aa6b54f..f66f107 100644 --- a/commands/booru.py +++ b/commands/booru.py @@ -21,7 +21,7 @@ async def reverse(context): urls = extractor.find_urls(context.options.url or "", only_unique=True, with_schema_only=True) if not urls: - await context.respond("**Invalid URL(s).**") + await context.respond("***Invalid URL(s)***") return await _reverse(context, urls) @@ -30,7 +30,7 @@ async def reverse(context): urls += [attachment.url for attachment in context.options.target.attachments if attachment.url not in urls] if not urls: - await context.respond("**No images found.**") + await context.respond("***No images found***") return selector = None @@ -49,7 +49,7 @@ async def reverse(context): await selector.wait() if selector.timed_out: - await context.interaction.edit_initial_response("**Timed out.**", components=None) + await context.interaction.edit_initial_response("***Timed out***", components=None) return urls = selector.selected @@ -63,17 +63,17 @@ async def on_reverse_error(event): match event.exception.__cause__: case pysaucenao.ShortLimitReachedException(): - error = "**API limit reached. Please try again in a minute.**" + error = "***API limit reached. Please try again in a minute***" case pysaucenao.DailyLimitReachedException(): - error = "**Daily API limit reached. Please try again tomorrow.**" + error = "***Daily API limit reached. Please try again tomorrow***" case pysaucenao.FileSizeLimitException() as url: - error = f"**Image file size too large.**\n{url}" + error = f"***Image file size too large***\n{url}" case pysaucenao.ImageSizeException() as url: - error = f"**Image resolution too small.**\n{url}" + error = f"***Image resolution too small***\n{url}" case pysaucenao.InvalidImageException() as url: - error = f"**Invalid image.**\n{url}" + error = f"***Invalid image***\n{url}" case pysaucenao.UnknownStatusCodeException(): - error = "**An unknown SauceNAO error has occurred. The service may be down.**" + error = "***An unknown SauceNAO error has occurred. The service may be down***" if error: try: @@ -92,9 +92,9 @@ async def _reverse(context, urls, *, selector=None): if not matches: if selector: - await context.interaction.edit_initial_response("**No matches found.**", components=None) + await context.interaction.edit_initial_response("***No matches found***", components=None) else: - await context.respond("**No matches found.**") + await context.respond("***No matches found***") return pages = [ @@ -109,7 +109,7 @@ async def _reverse(context, urls, *, selector=None): .set_footer(match["source"]) ) if match - else f"**No match found.**\n{urls[index]}" + else f"***No match found***\n{urls[index]}" for index, match in enumerate(matches) ] diff --git a/commands/master.py b/commands/master.py index 2723f78..6add516 100644 --- a/commands/master.py +++ b/commands/master.py @@ -20,19 +20,19 @@ async def master(context): extensions = [os.path.splitext(extension)[1][1:] for extension in context.bot.extensions] await context.respond( - f"**Reloaded `{'`, `'.join(extensions[:-1])}`, and `{extensions[-1]}` for you, master.**" + f"**Reloaded `{'`, `'.join(extensions[:-1])}`, and `{extensions[-1]}` for you, master**" ) case "sleep": - await context.respond("**Goodnight, master.**") + await context.respond("**Goodnight, master**") await context.bot.close() case "invite": await context.respond( f"https://discord.com/api/oauth2/authorize?client_id={c.config['client']}&permissions=1024&scope=bot%20applications.commands" ) case _: - await context.respond(f"**Hello, master.**") + await context.respond(f"**Hello, master**") else: - await context.respond(f"**{context.bot.application.owner.mention} is my master. 🐺**") + await context.respond(f"**{context.bot.application.owner.mention} is my master 🐺**") def load(bot): diff --git a/config.py b/config.py index b7ffc2a..269b97a 100644 --- a/config.py +++ b/config.py @@ -3,7 +3,7 @@ import hikari ACTIVITY = hikari.ActivityType.LISTENING -ERROR = "```❗ An internal error has occurred. This has been reported to my master. 🐺```" +ERROR = "```❗ An internal error has occurred. This has been reported to my master 🐺```" CONFIG = """\ guilds = [] # guild IDs to register commands, empty for global master = 0 # guild ID to register owner commands @@ -20,7 +20,7 @@ try: except FileNotFoundError: with open("config.toml", "w") as f: f.write(CONFIG) - print("config.toml created with default values. Restart when modified.") + print("config.toml created with default values. Restart when modified") exit()