diff --git a/discord/ext/tasks/__init__.py b/discord/ext/tasks/__init__.py index 240fc42e5..d2ae2c750 100644 --- a/discord/ext/tasks/__init__.py +++ b/discord/ext/tasks/__init__.py @@ -111,13 +111,13 @@ class Loop: raise await asyncio.sleep(backoff.delay()) else: + await sleep_until(self._next_iteration) + if self._stop_next_iteration: return self._current_loop += 1 if self._current_loop == self.count: break - - await sleep_until(self._next_iteration) except asyncio.CancelledError: self._is_being_cancelled = True raise