refactored get_stream_setting

This commit is contained in:
Rudi Grinberg 2012-10-31 10:56:52 -04:00
parent 82a8fe99ae
commit e3914c429d
1 changed files with 2 additions and 7 deletions

View File

@ -353,15 +353,10 @@ class AirtimeApiClient(object):
def get_stream_setting(self): def get_stream_setting(self):
logger = self.logger logger = self.logger
try: try: return self.services.get_stream_setting()
url = self.construct_url("get_stream_setting")
response = self.get_response_from_server(url)
response = json.loads(response)
except Exception, e: except Exception, e:
response = None
logger.error("Exception: %s", e) logger.error("Exception: %s", e)
return None
return response
def register_component(self, component): def register_component(self, component):
""" Purpose of this method is to contact the server with a "Hey its """ Purpose of this method is to contact the server with a "Hey its