mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-07-30 04:52:46 +00:00
MSC2946: Allow redactions/updates for space state events (#1712)
This commit is contained in:
parent
ef24ea2678
commit
2626525c65
3 changed files with 27 additions and 3 deletions
|
@ -333,7 +333,12 @@ func (w *walker) references(roomID string) (eventLookup, error) {
|
|||
}
|
||||
el := make(eventLookup)
|
||||
for _, ev := range events {
|
||||
el.set(ev)
|
||||
// only return events that have a `via` key as per MSC1772
|
||||
// else we'll incorrectly walk redacted events (as the link
|
||||
// is in the state_key)
|
||||
if gjson.GetBytes(ev.Content(), "via").Exists() {
|
||||
el.set(ev)
|
||||
}
|
||||
}
|
||||
return el, nil
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue