Remove unused function

This commit is contained in:
Ivan Habunek 2022-08-20 11:10:47 +02:00
parent 8e3a41e415
commit 235b13c257
No known key found for this signature in database
GPG Key ID: CDBD63C43A30BB95

View File

@ -14,21 +14,6 @@ class GQLError(Exception):
self.errors = errors self.errors = errors
def authenticated_get(url, params={}, headers={}):
headers['Client-ID'] = CLIENT_ID
response = httpx.get(url, params=params, headers=headers)
if 400 <= response.status_code < 500:
data = response.json()
# TODO: this does not look nice in the console since data["message"]
# can contain a JSON encoded object.
raise ConsoleError(data["message"])
response.raise_for_status()
return response
def authenticated_post(url, data=None, json=None, headers={}): def authenticated_post(url, data=None, json=None, headers={}):
headers['Client-ID'] = CLIENT_ID headers['Client-ID'] = CLIENT_ID