Cleanup unused modules and imports

* Ran code through PyFlakes
This commit is contained in:
JonnyWong16 2016-05-15 11:32:11 -07:00
commit cb8a5504f6
290 changed files with 45 additions and 78157 deletions

View file

@ -70,7 +70,6 @@ class HTTPHandler(object):
else:
handler = HTTPConnection(host=self.host, port=self.port, timeout=timeout)
token_string = ''
if not no_token:
if headers:
headers.update({'X-Plex-Token': self.token})
@ -86,10 +85,10 @@ class HTTPHandler(object):
request_status = response.status
request_content = response.read()
content_type = response.getheader('content-type')
except IOError, e:
except IOError as e:
logger.warn(u"Failed to access uri endpoint %s with error %s" % (uri, e))
return None
except Exception, e:
except Exception as e:
logger.warn(u"Failed to access uri endpoint %s. Is your server maybe accepting SSL connections only? %s" % (uri, e))
return None
except: