Skip to content

Commit

Permalink
Merge pull request #163 from dmunozv04/refresh-auth-after-disconnect
Browse files Browse the repository at this point in the history
Refresh auth after every disconnect
  • Loading branch information
dmunozv04 authored May 31, 2024
2 parents 5214190 + e92ba89 commit b56d744
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/iSponsorBlockTV/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,13 @@ async def is_available(self):
# Main subscription loop
async def loop(self):
lounge_controller = self.lounge_controller
while not lounge_controller.linked():
try:
self.logger.debug("Refreshing auth")
await lounge_controller.refresh_auth()
except:
await asyncio.sleep(10)
while not self.cancelled:
while not lounge_controller.linked():
try:
self.logger.debug("Refreshing auth")
await lounge_controller.refresh_auth()
except:
await asyncio.sleep(10)
while not (await self.is_available()) and not self.cancelled:
await asyncio.sleep(10)
try:
Expand Down

0 comments on commit b56d744

Please sign in to comment.