diff --git a/twython.py b/twython.py index dd0cd27..7015fa8 100644 --- a/twython.py +++ b/twython.py @@ -97,7 +97,7 @@ class setup: simplejson.load(self.opener.open("http://twitter.com/account/verify_credentials.json")) self.authenticated = True except HTTPError, e: - raise TwythonError("Authentication failed with your provided credentials. Try again? (%s failure)" % `e.code`, e.code) + raise AuthError("Authentication failed with your provided credentials. Try again? (%s failure)" % `e.code`, e.code) elif consumer_secret is not None and consumer_key is not None: self.consumer = oauth.OAuthConsumer(self.consumer_key, self.consumer_secret) self.connection = httplib.HTTPSConnection(SERVER) diff --git a/twython3k.py b/twython3k.py index 08db6ad..bc8fdb9 100644 --- a/twython3k.py +++ b/twython3k.py @@ -97,7 +97,7 @@ class setup: simplejson.load(self.opener.open("http://twitter.com/account/verify_credentials.json")) self.authenticated = True except HTTPError as e: - raise TwythonError("Authentication failed with your provided credentials. Try again? (%s failure)" % repr(e.code), e.code) + raise AuthError("Authentication failed with your provided credentials. Try again? (%s failure)" % repr(e.code), e.code) elif consumer_secret is not None and consumer_key is not None: self.consumer = oauth.OAuthConsumer(self.consumer_key, self.consumer_secret) self.connection = http.client.HTTPSConnection(SERVER)