File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed
crates/matrix-sdk-indexeddb/src/event_cache_store Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -162,6 +162,7 @@ impl_event_cache_store! {
162
162
. add_chunk(
163
163
room_id,
164
164
& types:: Chunk {
165
+ room_id: room_id. to_owned( ) ,
165
166
identifier: new. index( ) ,
166
167
previous: previous. map( |i| i. index( ) ) ,
167
168
next: next. map( |i| i. index( ) ) ,
@@ -185,6 +186,7 @@ impl_event_cache_store! {
185
186
. add_chunk(
186
187
room_id,
187
188
& types:: Chunk {
189
+ room_id: room_id. to_owned( ) ,
188
190
identifier: new. index( ) ,
189
191
previous: previous. map( |i| i. index( ) ) ,
190
192
next: next. map( |i| i. index( ) ) ,
Original file line number Diff line number Diff line change @@ -16,13 +16,15 @@ use matrix_sdk_base::{
16
16
deserialized_responses:: TimelineEvent , event_cache:: store:: extract_event_relation,
17
17
linked_chunk:: ChunkIdentifier ,
18
18
} ;
19
- use ruma:: OwnedEventId ;
19
+ use ruma:: { OwnedEventId , OwnedRoomId , RoomId } ;
20
20
use serde:: { Deserialize , Serialize } ;
21
21
22
22
/// Representation of a [`Chunk`](matrix_sdk_base::linked_chunk::Chunk)
23
23
/// which can be stored in IndexedDB.
24
24
#[ derive( Debug , Serialize , Deserialize ) ]
25
25
pub struct Chunk {
26
+ /// The room in which the chunk exists.
27
+ pub room_id : OwnedRoomId ,
26
28
/// The identifier of the chunk - i.e.,
27
29
/// [`ChunkIdentifier`](matrix_sdk_base::linked_chunk::ChunkIdentifier).
28
30
pub identifier : u64 ,
You can’t perform that action at this time.
0 commit comments