Queer European MD passionate about IT
Browse Source

davteutil.sleep_until was refactored

Davte 5 years ago
parent
commit
fb3e05681b
1 changed files with 1 additions and 2 deletions
  1. 1 2
      davtelepot/custombot.py

+ 1 - 2
davtelepot/custombot.py

@@ -1717,8 +1717,7 @@ class Bot(telepot.aio.Bot, Gettable):
             return
         inline_message_id = update['inline_message_id']
         self.to_be_obscured.append(inline_message_id)
-        while datetime.datetime.now() < when:
-            await sleep_until(when)
+        await sleep_until(when)
         try:
             await self.editMessageCaption(
                 inline_message_id,