Files
tuwunel/src/service/rooms/metadata/mod.rs

18 lines
304 B
Rust
Raw Normal View History

mod data;
pub use data::Data;
use ruma::RoomId;
2022-09-07 13:25:51 +02:00
use crate::Result;
2022-10-05 12:45:54 +02:00
pub struct Service {
db: Box<dyn Data>,
}
2021-08-12 23:04:00 +02:00
2022-10-05 12:45:54 +02:00
impl Service {
/// Checks if a room exists.
#[tracing::instrument(skip(self))]
pub fn exists(&self, room_id: &RoomId) -> Result<bool> {
self.db.exists(room_id)
2021-08-12 23:04:00 +02:00
}
}