Limit invoke_url retry's to 5

This commit is contained in:
Logykk 2021-12-02 17:20:32 +13:00 committed by GitHub
parent e00ad81c5e
commit 58fe9ae9e1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -89,7 +89,7 @@ class ZSpotify:
responseText = response.text
responseJson = response.json()
if 'error' in responseJson and tryCount < 20:
if 'error' in responseJson and tryCount < 5:
Printer.Print(PrintChannel.API_ERROR, f"Spotify API Error ({responseJson['error']['status']}): {responseJson['error']['message']}")
time.sleep(5)