1use std::string;
3use thiserror::Error;
4
5#[derive(Error, Debug)]
7#[non_exhaustive]
8pub enum KodikError {
9 #[cfg(feature = "async-impl")]
11 #[error("{0}")]
12 Reqwest(#[from] reqwest::Error),
13
14 #[cfg(feature = "blocking")]
16 #[error("{0}")]
17 Ureq(#[from] ureq::Error),
18
19 #[error("{0}")]
21 Decode(#[from] base64::DecodeError),
22
23 #[error("{0}")]
25 FromUtf8(#[from] string::FromUtf8Error),
26
27 #[error("{0}")]
29 Regex(&'static str),
30
31 #[error("link cannot be decoded {0}")]
33 LinkCannotBeDecoded(String),
34}