Skip to content
This repository has been archived by the owner on Jan 19, 2022. It is now read-only.

Commit

Permalink
add get_name classmethod to the TwitterRequester to fulfill the A…
Browse files Browse the repository at this point in the history
…PI and add

domain as an instance attribute for parity w/ the other requesters
  • Loading branch information
rafrombrc committed Apr 18, 2011
1 parent 5ed63e0 commit fccb04f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions linkoauth/backends/twitter_.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ def _get_credentials(self, access_token):
class TwitterRequester(object):
def __init__(self, account=None, oauth_token=None,
oauth_token_secret=None):
self.domain = domain
self.config = get_oauth_config(domain)
oauth_token = account and account.get('oauth_token') or oauth_token
oauth_token_secret = (account and account.get('oauth_token_secret')
Expand All @@ -152,6 +153,10 @@ def __init__(self, account=None, oauth_token=None,
secret=self.consumer_secret)
self.sigmethod = oauth.SignatureMethod_HMAC_SHA1()

@classmethod
def get_name(cls):
return domain

def _make_error(self, data, resp):
status = int(resp['status'])

Expand Down

0 comments on commit fccb04f

Please sign in to comment.