mirror of
https://gitlab.computer.surgery/matrix/grapevine.git
synced 2025-12-17 15:51:23 +01:00
generalize get_room_version
There are other fields of `m.room.create` events that are useful to individually extract without caring about the values of other fields.
This commit is contained in:
parent
c9c30fba30
commit
a4e1522875
4 changed files with 69 additions and 24 deletions
|
|
@ -38,6 +38,7 @@ use crate::{
|
|||
service::{
|
||||
globals::SigningKeys,
|
||||
pdu::{gen_event_id_canonical_json, PduBuilder},
|
||||
rooms::state::ExtractVersion,
|
||||
},
|
||||
services, utils, Ar, Error, PduEvent, Ra, Result,
|
||||
};
|
||||
|
|
@ -1324,8 +1325,10 @@ pub(crate) async fn invite_helper(
|
|||
(pdu, pdu_json, invite_room_state)
|
||||
};
|
||||
|
||||
let room_version_id =
|
||||
services().rooms.state.get_room_version(room_id)?;
|
||||
let room_version_id = services()
|
||||
.rooms
|
||||
.state
|
||||
.get_create_content::<ExtractVersion>(room_id)?;
|
||||
|
||||
let response = services()
|
||||
.sending
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue