2020-11-04 14:32:22 +00:00
|
|
|
pub mod discord_webhook;
|
2020-11-02 22:31:55 +00:00
|
|
|
pub mod pluralkit;
|
2020-11-02 20:54:23 +00:00
|
|
|
pub mod switchcounter;
|
2020-11-02 22:31:55 +00:00
|
|
|
|
|
|
|
pub type Result<T = ()> = std::result::Result<T, Error>;
|
|
|
|
|
|
|
|
#[derive(thiserror::Error, Debug)]
|
|
|
|
pub enum Error {
|
|
|
|
#[error("serde error: {0}")]
|
|
|
|
Serde(#[from] serde_json::Error),
|
|
|
|
|
|
|
|
#[error("ureq error: {0}")]
|
|
|
|
UReq(String),
|
|
|
|
|
|
|
|
#[error("http unsuccessful: {0}")]
|
|
|
|
HttpStatus(u16),
|
|
|
|
|
|
|
|
#[error("futures io error: {0}")]
|
|
|
|
FuturesIO(#[from] futures_io::Error),
|
|
|
|
|
|
|
|
#[error("systemmate mapping not found")]
|
|
|
|
SystemmateMappingNotFound(String),
|
|
|
|
}
|