Example #1
0
 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`**")
Example #2
0
 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))
Example #3
0
 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,
         ))
Example #4
0
 async def dev_reload_config(self, ctx):
     importlib_reload(self.bot.config)
     await ctx.send("I've successfully reloaded config!")