mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 11:16:07 -04:00
Comment
This commit is contained in:
parent
a297155a97
commit
e892457a03
2 changed files with 6 additions and 0 deletions
|
@ -984,6 +984,9 @@ def should_notify(old_state, new_state):
|
|||
def format_user_presence_state(state, now, include_user_id=True):
|
||||
"""Convert UserPresenceState to a format that can be sent down to clients
|
||||
and to other servers.
|
||||
|
||||
The "user_id" is optional so that this function can be used to format presence
|
||||
updates for client /sync responses and for federation /send requests.
|
||||
"""
|
||||
content = {
|
||||
"presence": state.state,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue