Skip to content

Commit

Permalink
Deprecate OAuthHandler alias
Browse files Browse the repository at this point in the history
  • Loading branch information
Harmon758 committed Jan 8, 2022
1 parent d4ceb1a commit cba7317
Showing 1 changed file with 16 additions and 1 deletion.
17 changes: 16 additions & 1 deletion tweepy/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,22 @@ def get_access_token(self, verifier=None):
except Exception as e:
raise TweepyException(e)

OAuthHandler = OAuth1UserHandler

class OAuthHandler(OAuth1UserHandler):
"""Alias for :class:`OAuth1UserHandler`
.. deprecated:: 4.5
Use :class:`OAuth1UserHandler` instead.
"""

def __init__(self, consumer_key, consumer_secret, access_token=None,
access_token_secret=None, callback=None):
warnings.warn(
"OAuthHandler is deprecated; use OAuth1UserHandler instead.",
DeprecationWarning
)
super().__init__(consumer_key, consumer_secret, access_token,
access_token_secret, callback)


class OAuth2AppHandler:
Expand Down

0 comments on commit cba7317

Please sign in to comment.