Skip to content

Commit b8cb4dc

Browse files
committed
Catch all errors for installing plugin
1 parent f0f8e05 commit b8cb4dc

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

cogs/plugins.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ async def plugin_add(self, ctx, *, plugin_name: str):
196196

197197
try:
198198
await self.load_plugin(*parsed_plugin)
199-
except DownloadError as exc:
199+
except Exception as exc:
200200
embed = discord.Embed(
201201
description=f'Unable to load this plugin: {exc}.',
202202
color=self.bot.main_color
@@ -214,13 +214,13 @@ async def plugin_add(self, ctx, *, plugin_name: str):
214214
'*Please note: any plugin that you install is of your OWN RISK*',
215215
color=self.bot.main_color
216216
)
217-
await message.edit(embed=embed)
217+
await ctx.send(embed=embed)
218218
else:
219219
embed = discord.Embed(
220220
description='Invalid plugin name format: use username/repo/plugin.',
221221
color=self.bot.main_color
222222
)
223-
await message.edit(embed=embed)
223+
await ctx.send(embed=embed)
224224

225225
@plugin.command(name='remove', aliases=['del', 'delete', 'rm'])
226226
@checks.has_permissions(PermissionLevel.OWNER)
@@ -345,7 +345,7 @@ async def plugin_enabled(self, ctx):
345345
)
346346
await ctx.send(embed=embed)
347347

348-
@plugin.group(invoke_without_command=True, name='registry', aliases=['list'])
348+
@plugin.group(invoke_without_command=True, name='registry', aliases=['list', 'info'])
349349
@checks.has_permissions(PermissionLevel.OWNER)
350350
async def plugin_registry(self, ctx, *, plugin_name: str = None):
351351
"""Shows a list of all approved plugins."""

0 commit comments

Comments
 (0)