code: Fix clippy warnings

This commit is contained in:
Sophie Herold 2023-02-12 01:19:47 +01:00
parent 1d034cd53d
commit 19c8d69dca
2 changed files with 4 additions and 6 deletions

View file

@ -18,7 +18,7 @@ pub fn query_attributes(file: &gio::File, attributes: Vec<&str>) -> anyhow::Resu
let mut attributes = attributes; let mut attributes = attributes;
let mut attr_str = String::from(attributes.remove(0)); let mut attr_str = String::from(attributes.remove(0));
for attr in attributes { for attr in attributes {
write!(attr_str, ",{}", attr)?; write!(attr_str, ",{attr}")?;
} }
file.query_info( file.query_info(
@ -36,7 +36,7 @@ pub async fn query_attributes_future(
let mut attr_str = String::from(*attributes.first().context("No attributes")?); let mut attr_str = String::from(*attributes.first().context("No attributes")?);
for attr in &attributes[1..] { for attr in &attributes[1..] {
write!(attr_str, ",{}", attr)?; write!(attr_str, ",{attr}")?;
} }
file.query_info_future( file.query_info_future(

View file

@ -412,10 +412,8 @@ impl LpImageView {
} }
if let Some(current_path) = self.current_path() { if let Some(current_path) = self.current_path() {
if self.model().contains(&current_path) { if self.model().contains(&current_path) && !self.imp().preserve_content.get() {
if !self.imp().preserve_content.get() { self.update_sliding_view(&current_path);
self.update_sliding_view(&current_path);
}
} }
} }
} }