fix: DMs show up as rooms

next
timokoesters 2020-06-26 10:07:02 +02:00
parent 8f06d0258a
commit 24c544f650
No known key found for this signature in database
GPG Key ID: 24DA7517711A2BA4
1 changed files with 4 additions and 0 deletions

View File

@ -504,6 +504,10 @@ impl Rooms {
if let Some(state_key) = &state_key { if let Some(state_key) = &state_key {
if let Some(prev_pdu) = self.room_state_get(&room_id, &event_type, &state_key)? { if let Some(prev_pdu) = self.room_state_get(&room_id, &event_type, &state_key)? {
unsigned.insert("prev_content".to_owned(), prev_pdu.content.clone()); unsigned.insert("prev_content".to_owned(), prev_pdu.content.clone());
unsigned.insert(
"prev_sender".to_owned(),
serde_json::to_value(prev_pdu.sender).expect("UserId::to_value always works"),
);
} }
} }