mirror of
https://gitlab.computer.surgery/matrix/grapevine.git
synced 2025-12-17 15:51:23 +01:00
Make tracing filter reload handles mutable
Makes the following diff nicer.
This commit is contained in:
parent
4cc390345a
commit
5eab758bd2
3 changed files with 9 additions and 7 deletions
|
|
@ -1176,12 +1176,13 @@ impl Service {
|
|||
"Reloading filters is disabled",
|
||||
));
|
||||
};
|
||||
let mut handles = handles.write().await;
|
||||
let handle = match backend {
|
||||
TracingBackend::Log => &handles.log,
|
||||
TracingBackend::Flame => &handles.flame,
|
||||
TracingBackend::Traces => &handles.traces,
|
||||
TracingBackend::Log => &mut handles.log,
|
||||
TracingBackend::Flame => &mut handles.flame,
|
||||
TracingBackend::Traces => &mut handles.traces,
|
||||
};
|
||||
let Some(handle) = handle else {
|
||||
let Some(handle) = handle.as_mut() else {
|
||||
return Ok(RoomMessageEventContent::text_plain(
|
||||
"Backend is disabled",
|
||||
));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue