mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-09-11 05:33:02 +02:00
refactor: Replace remaining std RwLocks
This commit is contained in:
parent
374fb2745c
commit
6d29098d1a
11 changed files with 32 additions and 90 deletions
|
@ -160,7 +160,6 @@ pub async fn handle_incoming_pdu<'a>(
|
|||
.globals
|
||||
.bad_event_ratelimiter
|
||||
.write()
|
||||
.expect("locked")
|
||||
.entry(prev_id.into())
|
||||
{
|
||||
| hash_map::Entry::Vacant(e) => {
|
||||
|
@ -181,13 +180,11 @@ pub async fn handle_incoming_pdu<'a>(
|
|||
let start_time = Instant::now();
|
||||
self.federation_handletime
|
||||
.write()
|
||||
.expect("locked")
|
||||
.insert(room_id.into(), (event_id.to_owned(), start_time));
|
||||
|
||||
defer! {{
|
||||
self.federation_handletime
|
||||
.write()
|
||||
.expect("locked")
|
||||
.remove(room_id);
|
||||
}};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue