fix(hydra): Idk maybe this will fix it

This commit is contained in:
nexy7574
2025-09-17 21:32:46 +01:00
parent 540cd28d44
commit a35f009d41
+9 -7
View File
@@ -195,13 +195,15 @@ async fn get_auth_chain_inner(
debug_error!(?event_id, ?e, "Could not find pdu mentioned in auth events"); debug_error!(?event_id, ?e, "Could not find pdu mentioned in auth events");
}, },
| Ok(pdu) => { | Ok(pdu) => {
if pdu.room_id.as_ref().is_some_and(|r| *r == *room_id) { if let Some(claimed_room_id) = pdu.room_id.clone() {
return Err!(Request(Forbidden(error!( if claimed_room_id != *room_id {
?event_id, return Err!(Request(Forbidden(error!(
?room_id, ?event_id,
wrong_room_id = ?pdu.room_id.unwrap(), ?room_id,
"auth event for incorrect room" wrong_room_id = ?pdu.room_id.unwrap(),
)))); "auth event for incorrect room"
))));
}
} }
for auth_event in &pdu.auth_events { for auth_event in &pdu.auth_events {