crypto: Disable the creation of encrypted event content for now.
It isn't possible to encrypted events using ruma anymore. This will need to be re-enabled once ruma gets back support for this.master
parent
704d8bc0ed
commit
86dc1ce3ca
|
@ -532,12 +532,15 @@ impl Client {
|
|||
) -> Result<MessageEventContent> {
|
||||
let mut olm = self.olm.lock().await;
|
||||
|
||||
match &mut *olm {
|
||||
Some(o) => Ok(MessageEventContent::Encrypted(
|
||||
o.encrypt(room_id, content).await?,
|
||||
)),
|
||||
None => panic!("Olm machine wasn't started"),
|
||||
}
|
||||
// TODO enable this again once we can send encrypted event
|
||||
// contents with ruma.
|
||||
// match &mut *olm {
|
||||
// Some(o) => Ok(MessageEventContent::Encrypted(
|
||||
// o.encrypt(room_id, content).await?,
|
||||
// )),
|
||||
// None => panic!("Olm machine wasn't started"),
|
||||
// }
|
||||
Ok(content)
|
||||
}
|
||||
|
||||
/// Get a tuple of device and one-time keys that need to be uploaded.
|
||||
|
|
|
@ -1290,10 +1290,12 @@ impl OlmMachine {
|
|||
)
|
||||
.await?;
|
||||
|
||||
user_messages.insert(
|
||||
DeviceIdOrAllDevices::DeviceId(device.device_id().clone()),
|
||||
EventJson::from(MessageEventContent::Encrypted(encrypted_content)),
|
||||
);
|
||||
// TODO enable this again once we can send encrypted event
|
||||
// contents with ruma.
|
||||
// user_messages.insert(
|
||||
// DeviceIdOrAllDevices::DeviceId(device.device_id().clone()),
|
||||
// EventJson::from(MessageEventContent::Encrypted(encrypted_content)),
|
||||
// );
|
||||
}
|
||||
|
||||
message_vec.push(ToDeviceRequest {
|
||||
|
|
Loading…
Reference in New Issue