Skip to content

Commit

Permalink
feat: changed reqwest to use rusttls lib instead native
Browse files Browse the repository at this point in the history
  • Loading branch information
paulobressan committed Apr 23, 2024
1 parent 9558346 commit 57e84e7
Show file tree
Hide file tree
Showing 3 changed files with 90 additions and 3 deletions.
88 changes: 88 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion visualizer/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ rand_core = "0.6"
bevy_rand = { version = "0.5", features = ["rand_chacha", "wyrand"] }
bevy_mod_picking = "0.18.2"
serde = { version = "1.0.198", features = ["derive"] }
reqwest = { version = "0.12.4", features = ["json"] }
reqwest = { version = "0.12.4", features = ["json", "rustls-tls"] }
async-compat = "0.2.3"
tracing = "0.1.40"
tracing-subscriber = "0.3.18"
Expand Down
3 changes: 1 addition & 2 deletions visualizer/src/api/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,7 @@ struct Response {
}

pub async fn get_assets() -> Result<Vec<AssetDto>, Box<dyn Error>> {
let client = reqwest::Client::new();

let client = reqwest::Client::builder().use_rustls_tls().build()?;
let query = r"
query QueryRoot($center: PositionInput!, $radius: Int!) {
objectsInRadius(center: $center, radius: $radius) {
Expand Down

0 comments on commit 57e84e7

Please sign in to comment.