Update timerole.py

This commit is contained in:
Ianardo DiCaprio 2019-08-14 22:02:34 +01:00 committed by GitHub
parent 5c68cca178
commit 42e7d9262f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -193,17 +193,8 @@ class Timerole(Cog):
async def check_day(self): async def check_day(self):
while self is self.bot.get_cog("Timerole"): while self is self.bot.get_cog("Timerole"):
tomorrow = datetime.now() + timedelta(days=1) print("Hmmmm")
midnight = datetime( await asyncio.sleep(30)
year=tomorrow.year,
month=tomorrow.month,
day=tomorrow.day,
hour=0,
minute=0,
second=0,
)
await asyncio.sleep((midnight - datetime.now()).seconds)
await self.timerole_update() await self.timerole_update()