Skip to content

Commit c26e555

Browse files
committed
clippy again
1 parent 4412be9 commit c26e555

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

src/store/fs/util/entity_manager.rs

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1042,24 +1042,18 @@ mod tests {
10421042
);
10431043
let (tx, rx) = oneshot::channel();
10441044
let killer = |arg: SpawnArg<Counters>| async move {
1045-
match arg {
1046-
SpawnArg::Active(_) => {
1047-
tx.send(()).ok();
1048-
panic!("Panic to kill the task");
1049-
}
1050-
_ => {}
1045+
if let SpawnArg::Active(_) = arg {
1046+
tx.send(()).ok();
1047+
panic!("Panic to kill the task");
10511048
}
10521049
};
10531050
// spawn a task that kills the entity actor
10541051
manager.spawn(1, killer).await?;
10551052
rx.await.expect("Failed to receive kill confirmation");
10561053
let (tx, rx) = oneshot::channel();
10571054
let counter = |arg: SpawnArg<Counters>| async move {
1058-
match arg {
1059-
SpawnArg::Dead => {
1060-
tx.send(()).ok();
1061-
}
1062-
_ => {}
1055+
if let SpawnArg::Dead = arg {
1056+
tx.send(()).ok();
10631057
}
10641058
};
10651059
// // spawn another task on the - now dead - entity actor

0 commit comments

Comments
 (0)