From 2347c1b440dd4003681e71ab1bf004a3f80795de Mon Sep 17 00:00:00 2001 From: Kristofers Solo Date: Mon, 27 Oct 2025 11:24:15 +0200 Subject: [PATCH] refactor: remove instaloader errors --- src/download.rs | 3 +-- src/error.rs | 8 -------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/src/download.rs b/src/download.rs index 2ad8fb8..73b85cf 100644 --- a/src/download.rs +++ b/src/download.rs @@ -34,7 +34,7 @@ pub struct DownloadResult { /// /// # Arguments /// -/// `cmd` is the command name (e.g. "yt-dlp" or "instaloader"). +/// `cmd` is the command name (e.g. "yt-dlp"). /// `args` are the command arguments (owned Strings so callers can build dynamic args). /// /// # Errors @@ -64,7 +64,6 @@ async fn run_command_in_tempdir(cmd: &str, args: &[&str]) -> Result Error::instaloader_failed(stderr), "yt-dlp" => Error::ytdlp_failed(stderr), _ => Error::Other(format!("{cmd} failed: {stderr}")), }; diff --git a/src/error.rs b/src/error.rs index 15fdb87..9ec0075 100644 --- a/src/error.rs +++ b/src/error.rs @@ -5,9 +5,6 @@ pub enum Error { #[error("io error: {0}")] Io(#[from] tokio::io::Error), - #[error("instaloader failed: {0}")] - InstaloaderFailed(String), - #[error("yt-dpl failed: {0}")] YTDLPFailed(String), @@ -39,11 +36,6 @@ impl Error { Self::Other(text.into()) } - #[inline] - pub fn instaloader_failed(text: impl Into) -> Self { - Self::InstaloaderFailed(text.into()) - } - #[inline] pub fn ytdlp_failed(text: impl Into) -> Self { Self::YTDLPFailed(text.into())