From e1d9cbe8c986719cdc27136f99d76382271a5c73 Mon Sep 17 00:00:00 2001 From: Thomas Eppers Date: Wed, 24 Nov 2021 17:49:23 +0100 Subject: [PATCH] fixed some clippy warnings --- src/widget/details.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/widget/details.rs b/src/widget/details.rs index d7db2c7..a42b549 100644 --- a/src/widget/details.rs +++ b/src/widget/details.rs @@ -12,9 +12,9 @@ impl Details { Self { details: vec![] } } - pub fn with_list(details: &Vec) -> Self { + pub fn with_list(details: &[crate::repository::TagDetails]) -> Self { let mut detail = Self { - details: details.clone(), + details: details.to_owned(), }; detail.details.sort_by(|a, b| a.arch.cmp(&b.arch)); @@ -40,7 +40,7 @@ impl Details { .get_details() .iter() .map(|l| { - tui::widgets::ListItem::new(format!("{}", l)) + tui::widgets::ListItem::new(l.to_string()) .style(Style::default().fg(Color::White).bg(Color::Black)) }) .collect();