From eef0c2d0e49f9b324b122131053e8dea27d0bb8c Mon Sep 17 00:00:00 2001 From: luckyturtledev Date: Mon, 19 Feb 2024 18:55:53 +0100 Subject: [PATCH] fix --- more-wallpapers/src/error.rs | 2 +- more-wallpapers/src/linux/xfce.rs | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/more-wallpapers/src/error.rs b/more-wallpapers/src/error.rs index e58042d..aac6f30 100644 --- a/more-wallpapers/src/error.rs +++ b/more-wallpapers/src/error.rs @@ -16,7 +16,7 @@ pub enum CommandError { CommandIO(&'static str, std::io::Error), #[cfg(target_os = "linux")] - #[error("{command} exit with code {exit_code:?}: {stderr:?}")] + #[error("{command:?} exit with code {exit_code:?}:\n{}", String::from_utf8_lossy(.stderr))] CommandStatus { command: &'static str, exit_code: Option, diff --git a/more-wallpapers/src/linux/xfce.rs b/more-wallpapers/src/linux/xfce.rs index cee6298..19755cf 100644 --- a/more-wallpapers/src/linux/xfce.rs +++ b/more-wallpapers/src/linux/xfce.rs @@ -33,7 +33,7 @@ pub(crate) fn get_screens() -> Result, WallpaperError> { let first = split.next(); let second = split.next(); let third = split.next(); - let fourth = split.next(); + let fourth = split.next(); if split.next().is_some() { //to long -> wrong key continue; @@ -49,7 +49,7 @@ pub(crate) fn get_screens() -> Result, WallpaperError> { } else { (format!("{}/{}", first, second), third, false) }; - if !(key_type == "last_image" || key_type == "image_style") { + if !(key_type == "last-image" || key_type == "image-style") { // wrong key continue; } @@ -60,7 +60,7 @@ pub(crate) fn get_screens() -> Result, WallpaperError> { mode: None, active, }); - if key_type == "last_image" { + if key_type == "last-image" { screen.wallpaper = Some(value.into()); } else { let mode = match value.as_str() {