diff options
author | Erik Johnston <erik@matrix.org> | 2014-09-06 02:23:36 +0100 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2014-09-06 02:23:36 +0100 |
commit | 781ff713ba65e9a8075063ee5112479afcb412ed (patch) | |
tree | 1df45adf38713cac9d045c43296f1026897c91c6 /synapse/api/events/__init__.py | |
parent | Document new invite key added to createRoom api (diff) | |
download | synapse-781ff713ba65e9a8075063ee5112479afcb412ed.tar.xz |
When getting a state event also include the previous content
Diffstat (limited to 'synapse/api/events/__init__.py')
-rw-r--r-- | synapse/api/events/__init__.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/synapse/api/events/__init__.py b/synapse/api/events/__init__.py index f95468fc65..5f300de108 100644 --- a/synapse/api/events/__init__.py +++ b/synapse/api/events/__init__.py @@ -157,7 +157,12 @@ class SynapseEvent(JsonEncodedObject): class SynapseStateEvent(SynapseEvent): - def __init__(self, **kwargs): + + valid_keys = SynapseEvent.valid_keys + [ + "prev_content", + ] + + def __init__(self, **kwargs): if "state_key" not in kwargs: kwargs["state_key"] = "" super(SynapseStateEvent, self).__init__(**kwargs) |