mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-09-12 00: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
|
@ -42,7 +42,6 @@ where
|
|||
.globals
|
||||
.bad_event_ratelimiter
|
||||
.read()
|
||||
.expect("locked")
|
||||
.get(prev_id)
|
||||
{
|
||||
// Exponential backoff
|
||||
|
@ -70,13 +69,11 @@ where
|
|||
let start_time = Instant::now();
|
||||
self.federation_handletime
|
||||
.write()
|
||||
.expect("locked")
|
||||
.insert(room_id.into(), ((*prev_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