use super::AuthenticationError;
use crate::headers::www_authenticate::Challenge;
pub trait AuthExtractorConfig {
type Inner: Challenge;
fn into_inner(self) -> Self::Inner;
}
impl<T> From<T> for AuthenticationError<<T as AuthExtractorConfig>::Inner>
where
T: AuthExtractorConfig,
{
fn from(config: T) -> Self {
AuthenticationError::new(config.into_inner())
}
}