mirror of
https://github.com/crunchy-labs/crunchy-cli.git
synced 2026-01-21 04:02:00 -06:00
Use native tls as default tls backend, add features to use rustls or openssl instead
This commit is contained in:
parent
185b65fc9b
commit
8eda8df3f7
6 changed files with 103 additions and 56 deletions
|
|
@ -276,7 +276,7 @@ async fn crunchyroll_session(cli: &mut Cli) -> Result<Crunchyroll> {
|
|||
builder = builder.user_agent(ua)
|
||||
}
|
||||
|
||||
#[cfg(any(feature = "openssl", feature = "openssl-static"))]
|
||||
#[cfg(any(feature = "openssl-tls", feature = "openssl-tls-static"))]
|
||||
let client = {
|
||||
let mut builder = builder.use_native_tls().tls_built_in_root_certs(false);
|
||||
|
||||
|
|
@ -288,7 +288,7 @@ async fn crunchyroll_session(cli: &mut Cli) -> Result<Crunchyroll> {
|
|||
|
||||
builder.build().unwrap()
|
||||
};
|
||||
#[cfg(not(any(feature = "openssl", feature = "openssl-static")))]
|
||||
#[cfg(not(any(feature = "openssl-tls", feature = "openssl-tls-static")))]
|
||||
let client = builder.build().unwrap();
|
||||
|
||||
client
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue