Update dependencies and send displayname updates again

This commit is contained in:
timokoesters 2020-05-08 21:13:52 +02:00
parent 8f67c01efd
commit 551308e9a8
No known key found for this signature in database
GPG key ID: 356E705610F626D5
6 changed files with 123 additions and 112 deletions

View file

@ -17,7 +17,7 @@ pub struct Rooms {
pub(super) pduid_pdu: sled::Tree, // PduId = RoomId + Count
pub(super) eventid_pduid: sled::Tree,
pub(super) roomid_pduleaves: sled::Tree,
pub(super) roomstateid_pdu: sled::Tree, // Room + StateType + StateKey
pub(super) roomstateid_pdu: sled::Tree, // RoomStateId = Room + StateType + StateKey
pub(super) userroomid_joined: sled::Tree,
pub(super) roomuserid_joined: sled::Tree,
@ -29,11 +29,10 @@ pub struct Rooms {
impl Rooms {
/// Checks if a room exists.
pub fn exists(&self, room_id: &RoomId) -> Result<bool> {
// Look for PDUs in that room.
let mut prefix = room_id.to_string().as_bytes().to_vec();
prefix.push(0xff);
// Look for PDUs in that room.
Ok(self
.pduid_pdu
.get_gt(&prefix)?