Properly type stored EDUs

This commit is contained in:
Lambda 2024-08-26 17:10:43 +00:00
parent 26322d5a95
commit cce83beedb
3 changed files with 29 additions and 20 deletions

View file

@ -5,6 +5,7 @@ use ruma::{
client::{error::ErrorKind, to_device::send_event_to_device},
federation::{self, transactions::edu::DirectDeviceContent},
},
serde::Raw,
to_device::DeviceIdOrAllDevices,
};
@ -40,7 +41,7 @@ pub(crate) async fn send_event_to_device_route(
services().sending.send_reliable_edu(
target_user_id.server_name(),
serde_json::to_vec(
Raw::new(
&federation::transactions::edu::Edu::DirectToDevice(
DirectDeviceContent {
sender: sender_user.clone(),