Fix clippy warning

This commit is contained in:
Matthew Esposito 2023-12-26 23:15:06 -05:00
parent e452b8d6b5
commit 47822d8d6c
No known key found for this signature in database

View File

@ -212,7 +212,7 @@ impl Device {
// Waiting on fastrand 2.0.0 for the `choose` function
// https://github.com/smol-rs/fastrand/pull/59/
fn choose<T: Copy>(list: &[T]) -> T {
*fastrand::choose_multiple(list.into_iter(), 1)[0]
*fastrand::choose_multiple(list.iter(), 1)[0]
}
#[tokio::test(flavor = "multi_thread", worker_threads = 1)]