mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-11-14 23:40:45 -05:00
Add missing type hints to synapse.api. (#11109)
* Convert UserPresenceState to attrs. * Remove args/kwargs from error classes and explicitly pass msg/errorcode.
This commit is contained in:
parent
cc33d9eee2
commit
3ab55d43bd
10 changed files with 84 additions and 99 deletions
|
|
@ -1489,7 +1489,7 @@ def format_user_presence_state(
|
|||
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}
|
||||
content: JsonDict = {"presence": state.state}
|
||||
if include_user_id:
|
||||
content["user_id"] = state.user_id
|
||||
if state.last_active_ts:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue