2020-04-05 06:00:13 +02:00
|
|
|
import sys
|
2020-04-05 13:09:16 +02:00
|
|
|
|
2020-04-05 06:00:13 +02:00
|
|
|
from modules.base import BaseClassPython
|
|
|
|
|
|
|
|
|
|
|
|
class MainClass(BaseClassPython):
|
|
|
|
name = "Restart"
|
|
|
|
help = {
|
|
|
|
"description": "Module gérant les redémarrages de Nikola Tesla",
|
|
|
|
"commands": {
|
|
|
|
"`{prefix}{command}`": "Redémarre le bot.",
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
async def command(self, message, args, kwargs):
|
|
|
|
await message.channel.send(f"{message.author.mention}, Le bot va redémarrer.")
|
|
|
|
await self.client.logout()
|
2020-04-05 13:09:16 +02:00
|
|
|
# TODO: Faut vraiment faire mieux
|
2020-04-05 06:00:13 +02:00
|
|
|
sys.exit(0)
|