async def reloadconf(self, ctx): try: importlib_reload(self.bot.config) except Exception as e: await ctx.send(f"**`ERROR:`** {type(e).__name__} - {e}") else: await ctx.send("**`SUCCESS`**")
async def reload_import(self, lib, command_id): importlib_reload(getattr(self.bot, lib)) payload = { "output": "Success", "command_id": command_id, } await self.bot.redis.execute("PUBLISH", self.ipc_channel, json.dumps(payload))
async def reloadconf(self, ctx): try: importlib_reload(self.bot.config) except Exception as e: await ctx.send(embed=discord.Embed( description=f"ERROR: {type(e).__name__} - {e}", colour=self.bot.error_colour)) else: await ctx.send(embed=discord.Embed( description="Successfully reloaded the configurations.", colour=self.bot.primary_colour, ))
async def dev_reload_config(self, ctx): importlib_reload(self.bot.config) await ctx.send("I've successfully reloaded config!")