mirror of
https://github.com/jellyfin/jellyfin-kodi.git
synced 2024-12-24 01:36:11 +00:00
Another follow up
Use a while loop instead.
This commit is contained in:
parent
8944012821
commit
de527327a5
2 changed files with 9 additions and 2 deletions
|
@ -269,7 +269,7 @@ class DownloadUtils():
|
|||
if r.headers['X-Application-Error-Code'] == "ParentalControl":
|
||||
# Parental control - access restricted
|
||||
WINDOW.setProperty("Server_status", "restricted")
|
||||
xbmcgui.Dialog().notification("Emby server", "Access restricted.", xbmcgui.NOTIFICATION_ERROR)
|
||||
xbmcgui.Dialog().notification("Emby server", "Access restricted.", xbmcgui.NOTIFICATION_ERROR, time=5000)
|
||||
return False
|
||||
|
||||
elif (status == "401") or (status == "Auth"):
|
||||
|
|
|
@ -145,11 +145,18 @@ class Service():
|
|||
break
|
||||
#WebSocketThread().processPendingActions()
|
||||
else:
|
||||
user.hasAccess()
|
||||
|
||||
if self.warn_auth:
|
||||
self.logMsg("Not authenticated yet.", 1)
|
||||
self.warn_auth = False
|
||||
|
||||
while user.HasAccess == False:
|
||||
user.hasAccess()
|
||||
if self.KodiMonitor.waitForAbort(5):
|
||||
# Abort was requested while waiting. We should exit
|
||||
break
|
||||
|
||||
|
||||
else:
|
||||
# Wait until server becomes online or shut down is requested
|
||||
while not self.KodiMonitor.abortRequested():
|
||||
|
|
Loading…
Reference in a new issue