fix: API in ::certs::insecure

This commit is contained in:
DarkCat09 2024-08-06 11:08:35 +04:00
parent dcd6359fcc
commit a1ddbed7a9
Signed by: DarkCat09
GPG key ID: 0A26CD5B3345D6E3

View file

@ -5,11 +5,11 @@ use tokio_rustls::rustls::{
};
#[derive(Debug)]
pub struct AllowAllCertVerifier(CryptoProvider);
pub struct AllowAllCertVerifier(std::sync::Arc<CryptoProvider>);
impl AllowAllCertVerifier {
fn yes_i_know_what_i_am_doing(provider: CryptoProvider) -> Self {
AllowAllCertVerifier(provider)
pub fn yes_i_know_what_i_am_doing() -> Self {
AllowAllCertVerifier(CryptoProvider::get_default().unwrap().clone())
}
}