mirror of
https://github.com/rembo10/headphones.git
synced 2026-05-22 11:27:45 +01:00
Fixed rate limiting, the provided sleep interval was pretty much ignored because any value > 0 was considered to be a limit of 1 request/second
This commit is contained in:
+2
-1
@@ -57,7 +57,8 @@ def startmb():
|
||||
if sleepytime == 0:
|
||||
musicbrainzngs.set_rate_limit(False)
|
||||
else:
|
||||
musicbrainzngs.set_rate_limit(True)
|
||||
#calling it with an it ends up blocking all requests after the first
|
||||
musicbrainzngs.set_rate_limit(limit_or_interval=float(sleepytime))
|
||||
|
||||
# Add headphones credentials
|
||||
if headphones.MIRROR == "headphones":
|
||||
|
||||
Reference in New Issue
Block a user