Skip to content

Commit

Permalink
fixed async/logout | added _get_user_state
Browse files Browse the repository at this point in the history
  • Loading branch information
d60 committed Jun 5, 2024
1 parent cdde4b9 commit e095412
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion twikit/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
A Python library for interacting with the Twitter API.
"""

__version__ = '1.7.2'
__version__ = '1.7.3'

from ._captcha import Capsolver
from .bookmark import BookmarkFolder
Expand Down
2 changes: 1 addition & 1 deletion twikit/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -424,7 +424,7 @@ def logout(self) -> Response:
"""
Logs out of the currently logged-in account.
"""
_, response = self.http.post(
_, response = self.post(
Endpoint.LOGOUT,
headers=self._base_headers
)
Expand Down
4 changes: 3 additions & 1 deletion twikit/twikit_async/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -5240,7 +5240,9 @@ async def _update_subscriptions(

return _payload_from_data(response)

async def _get_user_state(self) -> Literal['normal', 'bounced', 'suspended']:
async def _get_user_state(
self
) -> Literal['normal', 'bounced', 'suspended']:
response, _ = await self.get(
Endpoint.USER_STATE,
headers=self._base_headers
Expand Down

0 comments on commit e095412

Please sign in to comment.