mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 14:06:02 -04:00
Rename 'state' presence key to the much more obvious 'presence'; maintain a legacy 'state' copy for now
This commit is contained in:
parent
f500dd627a
commit
02f4e3b3ff
7 changed files with 147 additions and 78 deletions
|
@ -48,7 +48,11 @@ class PresenceStatusRestServlet(RestServlet):
|
|||
try:
|
||||
content = json.loads(request.content.read())
|
||||
|
||||
state["state"] = content.pop("state")
|
||||
# Legacy handling
|
||||
if "state" in content:
|
||||
state["presence"] = content.pop("state")
|
||||
else:
|
||||
state["presence"] = content.pop("presence")
|
||||
|
||||
if "status_msg" in content:
|
||||
state["status_msg"] = content.pop("status_msg")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue