forked from mirror/grapevine
Mark events as not visible when they're not found or in the wrong room
This commit is contained in:
parent
f965bf2b6a
commit
1ba96b9534
1 changed files with 8 additions and 0 deletions
|
@ -215,6 +215,14 @@ impl Service {
|
|||
) -> Result<bool> {
|
||||
let lookup = Lookup::VisibilityForUser;
|
||||
|
||||
let Some(pdu) = services().rooms.timeline.get_pdu(event_id)? else {
|
||||
return Ok(false);
|
||||
};
|
||||
|
||||
if pdu.room_id() != room_id {
|
||||
return Ok(false);
|
||||
}
|
||||
|
||||
let Some(shortstatehash) = self.pdu_shortstatehash(event_id)? else {
|
||||
return Ok(true);
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue