|
14 | 14 |
|
15 | 15 | use std::{collections::BTreeMap, fmt, sync::Arc};
|
16 | 16 |
|
17 |
| -#[cfg(doc)] |
18 |
| -use ruma::events::AnyTimelineEvent; |
19 | 17 | use ruma::{
|
20 | 18 | DeviceKeyAlgorithm, OwnedDeviceId, OwnedEventId, OwnedUserId,
|
21 | 19 | events::{
|
22 |
| - AnyMessageLikeEvent, AnySyncMessageLikeEvent, AnySyncTimelineEvent, AnyToDeviceEvent, |
| 20 | + AnySyncMessageLikeEvent, AnySyncTimelineEvent, AnyTimelineEvent, AnyToDeviceEvent, |
23 | 21 | MessageLikeEventType,
|
24 | 22 | },
|
25 | 23 | push::Action,
|
@@ -651,7 +649,7 @@ impl TimelineEvent {
|
651 | 649 | }
|
652 | 650 |
|
653 | 651 | /// Replace the raw event included in this item by another one.
|
654 |
| - pub fn replace_raw(&mut self, replacement: Raw<AnyMessageLikeEvent>) { |
| 652 | + pub fn replace_raw(&mut self, replacement: Raw<AnyTimelineEvent>) { |
655 | 653 | match &mut self.kind {
|
656 | 654 | TimelineEventKind::Decrypted(decrypted) => decrypted.event = replacement,
|
657 | 655 | TimelineEventKind::UnableToDecrypt { event, .. }
|
@@ -843,7 +841,7 @@ pub struct DecryptedRoomEvent {
|
843 | 841 | /// encrypted payload *always contains* a room id, by the [spec].
|
844 | 842 | ///
|
845 | 843 | /// [spec]: https://spec.matrix.org/v1.12/client-server-api/#mmegolmv1aes-sha2
|
846 |
| - pub event: Raw<AnyMessageLikeEvent>, |
| 844 | + pub event: Raw<AnyTimelineEvent>, |
847 | 845 |
|
848 | 846 | /// The encryption info about the event.
|
849 | 847 | pub encryption_info: Arc<EncryptionInfo>,
|
|
0 commit comments