fix(appservices): don't panic on empty registration url
perf(appservices): cache regex for namespaces
This commit is contained in:
parent
a095e02d04
commit
fa930182ae
15 changed files with 335 additions and 244 deletions
|
@ -4,7 +4,7 @@ use std::{
|
|||
};
|
||||
|
||||
use lru_cache::LruCache;
|
||||
use tokio::sync::Mutex;
|
||||
use tokio::sync::{Mutex, RwLock};
|
||||
|
||||
use crate::{Config, Result};
|
||||
|
||||
|
@ -56,7 +56,10 @@ impl Services {
|
|||
config: Config,
|
||||
) -> Result<Self> {
|
||||
Ok(Self {
|
||||
appservice: appservice::Service { db },
|
||||
appservice: appservice::Service {
|
||||
db,
|
||||
registration_info: RwLock::new(HashMap::new()),
|
||||
},
|
||||
pusher: pusher::Service { db },
|
||||
rooms: rooms::Service {
|
||||
alias: rooms::alias::Service { db },
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue