1
0
Fork 0
mirror of https://github.com/myned/modufur.git synced 2024-12-24 14:27:27 +00:00

Changed "restart_(ch to chan)" to "startup_" for clarity with shutdown

This commit is contained in:
Myned 2017-10-30 23:28:37 -04:00
parent ba10b668a7
commit 801ee2be71
2 changed files with 8 additions and 8 deletions

View file

@ -30,8 +30,8 @@ class Bot:
await self.bot.get_channel(u.config['info_channel']).send('**Shutting down** 🌙 . . .')
u.temp['restart_ch'] = ctx.channel.id
u.temp['restart_msg'] = ctx.message.id
u.temp['startup_chan'] = ctx.channel.id
u.temp['startup_msg'] = ctx.message.id
u.dump(u.temp, 'temp.pkl')
# loop = self.bot.loop.all_tasks()
@ -52,8 +52,8 @@ class Bot:
await self.bot.get_channel(u.config['info_channel']).send('**Restarting** 💤 . . .')
# u.notify('R E S T A R T I N G')
u.temp['restart_ch'] = ctx.channel.id
u.temp['restart_msg'] = ctx.message.id
u.temp['startup_chan'] = ctx.channel.id
u.temp['startup_msg'] = ctx.message.id
u.dump(u.temp, 'temp.pkl')
# loop = self.bot.loop.all_tasks()

View file

@ -51,8 +51,8 @@ async def on_ready():
await bot.get_channel(u.config['info_channel']).send('**Started** ☀️ .')
# u.notify('C O N N E C T E D')
if u.temp:
channel = bot.get_channel(u.temp['restart_ch'])
message = await channel.get_message(u.temp['restart_msg'])
channel = bot.get_channel(u.temp['startup_chan'])
message = await channel.get_message(u.temp['startup_msg'])
await message.add_reaction('')
u.temp.clear()
@ -70,8 +70,8 @@ async def on_error(error, *args, **kwargs):
await bot.get_user(u.config['owner_id']).send('**ERROR** ⚠\n```\n{}```'.format(error))
await bot.get_channel(u.config['info_channel']).send('**ERROR** ⚠\n```\n{}```'.format(error))
if u.temp:
channel = bot.get_channel(u.temp['restart_ch'])
message = await channel.get_message(u.temp['restart_msg'])
channel = bot.get_channel(u.temp['startup_chan'])
message = await channel.get_message(u.temp['startup_msg'])
await message.add_reaction('')
u.temp.clear()
# u.notify('E R R O R')