mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-07-11 04:17:58 +00:00
Remove on_status event. Superseded by on_member_update.
This commit is contained in:
parent
49d78c69c7
commit
63565026c4
@ -120,12 +120,11 @@ class ConnectionState:
|
|||||||
member.status = Status(member.status)
|
member.status = Status(member.status)
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
member.game_id = data.get('game_id')
|
member.game_id = data.get('game_id')
|
||||||
member.name = user.get('username', member.name)
|
member.name = user.get('username', member.name)
|
||||||
member.avatar = user.get('avatar', member.avatar)
|
member.avatar = user.get('avatar', member.avatar)
|
||||||
|
|
||||||
# call the event now
|
|
||||||
self.dispatch('status', member, old_member.game_id, old_member.status)
|
|
||||||
self.dispatch('member_update', old_member, member)
|
self.dispatch('member_update', old_member, member)
|
||||||
|
|
||||||
def parse_user_update(self, data):
|
def parse_user_update(self, data):
|
||||||
|
@ -207,14 +207,6 @@ to handle it, which defaults to print a traceback and ignore the exception.
|
|||||||
:param before: A :class:`Message` of the previous version of the message.
|
:param before: A :class:`Message` of the previous version of the message.
|
||||||
:param after: A :class:`Message` of the current version of the message.
|
:param after: A :class:`Message` of the current version of the message.
|
||||||
|
|
||||||
.. function:: on_status(member, old_game_id, old_status)
|
|
||||||
|
|
||||||
Called whenever a :class:`Member` changes their status or game playing status.
|
|
||||||
|
|
||||||
:param member: The :class:`Member` who has had their status changed.
|
|
||||||
:param old_game_id: The game ID the member had before it changed.
|
|
||||||
:param old_status: The status the member had before it changed.
|
|
||||||
|
|
||||||
.. function:: on_channel_delete(channel)
|
.. function:: on_channel_delete(channel)
|
||||||
on_channel_create(channel)
|
on_channel_create(channel)
|
||||||
|
|
||||||
@ -250,6 +242,7 @@ to handle it, which defaults to print a traceback and ignore the exception.
|
|||||||
- game playing
|
- game playing
|
||||||
- avatar
|
- avatar
|
||||||
- nickname
|
- nickname
|
||||||
|
- roles
|
||||||
|
|
||||||
:param before: The :class:`Member` that updated their profile with the old info.
|
:param before: The :class:`Member` that updated their profile with the old info.
|
||||||
:param after: The :class:`Member` that updated their profile with the updated info.
|
:param after: The :class:`Member` that updated their profile with the updated info.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user