diff options
| author | 2021-09-03 00:31:46 -0700 | |
|---|---|---|
| committer | 2021-09-03 00:31:46 -0700 | |
| commit | 33f50730aa8ef29d4496f218527a1f4c69961a8e (patch) | |
| tree | c40e2f23e55119fb33f83271d227103cb9be7c6f /bot/exts/utils/extensions.py | |
| parent | Merge pull request #802 from python-discord/decorator-factory/typehints-fix (diff) | |
| parent | Merge branch 'main' into android-codeblock-fix (diff) | |
Merge pull request #839 from python-discord/android-codeblock-fix
Fix android codeblock rendering inconsistency
Diffstat (limited to 'bot/exts/utils/extensions.py')
| -rw-r--r-- | bot/exts/utils/extensions.py | 8 | 
1 files changed, 4 insertions, 4 deletions
| diff --git a/bot/exts/utils/extensions.py b/bot/exts/utils/extensions.py index 521bfb47..424bacac 100644 --- a/bot/exts/utils/extensions.py +++ b/bot/exts/utils/extensions.py @@ -61,7 +61,7 @@ class Extension(commands.Converter):              names = "\n".join(matches)              raise commands.BadArgument(                  f":x: `{argument}` is an ambiguous extension name. " -                f"Please use one of the following fully-qualified names.```\n{names}```" +                f"Please use one of the following fully-qualified names.```\n{names}\n```"              )          elif matches:              return matches[0] @@ -111,7 +111,7 @@ class Extensions(commands.Cog):          blacklisted = "\n".join(UNLOAD_BLACKLIST & set(extensions))          if blacklisted: -            msg = f":x: The following extension(s) may not be unloaded:```{blacklisted}```" +            msg = f":x: The following extension(s) may not be unloaded:```\n{blacklisted}\n```"          else:              if "*" in extensions or "**" in extensions:                  extensions = set(self.bot.extensions.keys()) - UNLOAD_BLACKLIST @@ -214,7 +214,7 @@ class Extensions(commands.Cog):          if failures:              failures = "\n".join(f"{ext}\n    {err}" for ext, err in failures.items()) -            msg += f"\nFailures:```{failures}```" +            msg += f"\nFailures:```\n{failures}\n```"          log.debug(f"Batch {verb}ed extensions.") @@ -241,7 +241,7 @@ class Extensions(commands.Cog):              log.exception(f"Extension '{ext}' failed to {verb}.")              error_msg = f"{e.__class__.__name__}: {e}" -            msg = f":x: Failed to {verb} extension `{ext}`:\n```{error_msg}```" +            msg = f":x: Failed to {verb} extension `{ext}`:\n```\n{error_msg}\n```"          else:              msg = f":ok_hand: Extension successfully {verb}ed: `{ext}`."              log.debug(msg[10:]) | 
