mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 12:26:02 -04:00
Clean up event accesses and tests
This is in preparation to refactor FrozenEvent to support different event formats for different room versions
This commit is contained in:
parent
1b21e771d0
commit
b86d05a279
5 changed files with 7 additions and 10 deletions
|
@ -311,10 +311,10 @@ class HttpPusher(object):
|
|||
]
|
||||
}
|
||||
}
|
||||
if event.type == 'm.room.member':
|
||||
if event.type == 'm.room.member' and event.is_state():
|
||||
d['notification']['membership'] = event.content['membership']
|
||||
d['notification']['user_is_target'] = event.state_key == self.user_id
|
||||
if self.hs.config.push_include_content and 'content' in event:
|
||||
if self.hs.config.push_include_content and event.content:
|
||||
d['notification']['content'] = event.content
|
||||
|
||||
# We no longer send aliases separately, instead, we send the human
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue