mirror of
https://github.com/rembo10/headphones.git
synced 2026-07-21 16:34:01 +01:00
Fix using lock/rate limit for requests.*
This commit is contained in:
@@ -57,7 +57,7 @@ def request_response(url, method="get", auto_raise=True,
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
# Request URL and wait for response
|
# Request URL and wait for response
|
||||||
if lock is not None:
|
with lock:
|
||||||
logger.debug("Requesting URL via %s method: %s", method.upper(), url)
|
logger.debug("Requesting URL via %s method: %s", method.upper(), url)
|
||||||
response = request_method(url, **kwargs)
|
response = request_method(url, **kwargs)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user