Add more error handling to AgoraDesk library
This commit is contained in:
parent
1e685c9f8d
commit
2f0cb38abd
|
@ -114,6 +114,12 @@ class AgoraDesk:
|
|||
result["status"] = response.status_code
|
||||
result["response"] = {"error": {"message": response.text}}
|
||||
return result
|
||||
except httpx.ReadTimeout:
|
||||
result["message"] = "Read timed out"
|
||||
if response:
|
||||
result["status"] = response.status_code
|
||||
result["response"] = {"error": {"message": response.text}}
|
||||
return result
|
||||
|
||||
# Account related API Methods
|
||||
# ===========================
|
||||
|
|
Loading…
Reference in New Issue