Skip to content

Commit 6929d3d

Browse files
committed
-) Fix for resetting authentication task
1 parent b1e5a10 commit 6929d3d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pymyq/api.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,9 +197,10 @@ async def request(
197197
authentication_task = await self.authenticate(wait=False)
198198
if authentication_task.done():
199199
_LOGGER.debug("Scheduled token refresh completed, ensuring no exception.")
200+
self._authentication_task = None
200201
try:
201202
# Get the result so any exception is raised.
202-
self._authentication_task.result()
203+
authentication_task.result()
203204
except asyncio.CancelledError:
204205
pass
205206
except (RequestError, AuthenticationError) as auth_err:

0 commit comments

Comments
 (0)