Browse Source

don't set json content-type/accept headers for download requests

the response type is NOT json, this was just wrong
master
Jonathan Strong 2 years ago
parent
commit
a4a0864f3c
  1. 5
      src/main.rs

5
src/main.rs

@ -548,8 +548,9 @@ async fn download_versions(
debug!(?url, "downloading..."); debug!(?url, "downloading...");
let req = http_client let req = http_client
.get(url) .get(url)
.header(CONTENT_TYPE, "application/json") //.header(CONTENT_TYPE, "application/json")
.header(ACCEPT, "application/json"); //.header(ACCEPT, "application/json")
;
let req = if let Some(token) = config.registry.auth_token.as_deref() { let req = if let Some(token) = config.registry.auth_token.as_deref() {
req.header(AUTHORIZATION, token) req.header(AUTHORIZATION, token)

Loading…
Cancel
Save