use torn-api 0.6 for the key pool
This commit is contained in:
parent
fee278e895
commit
af39b03ef2
3 changed files with 16 additions and 2 deletions
|
|
@ -29,6 +29,20 @@ where
|
|||
Response(ResponseError),
|
||||
}
|
||||
|
||||
impl<S, C> KeyPoolError<S, C>
|
||||
where
|
||||
S: std::error::Error,
|
||||
C: std::error::Error,
|
||||
{
|
||||
#[inline(always)]
|
||||
pub fn api_code(&self) -> Option<u8> {
|
||||
match self {
|
||||
Self::Response(why) => why.api_code(),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
pub trait ApiKey: Sync + Send + std::fmt::Debug + Clone {
|
||||
type IdType: PartialEq + Eq + std::hash::Hash + Send + Sync + std::fmt::Debug + Clone;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue