check_live_stream_auth fixed
This commit is contained in:
parent
4ad1468313
commit
3ed762bc38
|
@ -293,26 +293,8 @@ class AirtimeApiClient(object):
|
||||||
return response
|
return response
|
||||||
|
|
||||||
def check_live_stream_auth(self, username, password, dj_type):
|
def check_live_stream_auth(self, username, password, dj_type):
|
||||||
"""
|
return self.services.check_live_stream_auth(
|
||||||
TODO: Why are we using print statements here? Possibly use logger that
|
username=username, password=password, dj_type=dj_type)
|
||||||
is directed to stdout. -MK
|
|
||||||
"""
|
|
||||||
|
|
||||||
response = ''
|
|
||||||
try:
|
|
||||||
url = self.construct_url("check_live_stream_auth")
|
|
||||||
url = url.replace("%%username%%", username)
|
|
||||||
url = url.replace("%%djtype%%", dj_type)
|
|
||||||
url = url.replace("%%password%%", password)
|
|
||||||
|
|
||||||
response = self.get_response_from_server(url)
|
|
||||||
response = json.loads(response)
|
|
||||||
except Exception, e:
|
|
||||||
print "Exception: %s", e
|
|
||||||
print "traceback: %s", traceback.format_exc()
|
|
||||||
response = None
|
|
||||||
|
|
||||||
return response
|
|
||||||
|
|
||||||
def construct_url(self,config_action_key):
|
def construct_url(self,config_action_key):
|
||||||
"""Constructs the base url for every request"""
|
"""Constructs the base url for every request"""
|
||||||
|
|
Loading…
Reference in New Issue