Skip to content

Commit

Permalink
ref(api): Remove dead code (#2217)
Browse files Browse the repository at this point in the history
This dead code caused a CI linter failure in `master`. Likely, we did
not update #2212 with the changes from #2213 before merging.
  • Loading branch information
szokeasaurusrex authored Nov 6, 2024
1 parent a3ef685 commit 632ab83
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions src/api/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ impl fmt::Display for Method {
/// Represents an API request. This can be customized before
/// sending but only sent once.
pub struct ApiRequest {
url: String,
handle: r2d2::PooledConnection<CurlConnectionManager>,
headers: curl::easy::List,
is_authenticated: bool,
Expand All @@ -121,7 +120,6 @@ pub struct ApiRequest {
/// Represents an API response.
#[derive(Clone, Debug)]
pub struct ApiResponse {
url: String,
status: u32,
headers: Vec<String>,
body: Option<Vec<u8>>,
Expand Down Expand Up @@ -1667,7 +1665,6 @@ impl ApiRequest {
handle.url(url)?;

let request = ApiRequest {
url: url.to_owned(),
handle,
headers,
is_authenticated: false,
Expand Down Expand Up @@ -1774,12 +1771,10 @@ impl ApiRequest {
let headers = self.get_headers();
self.handle.http_headers(headers)?;
let body = self.body.as_deref();
let url = self.url.clone();
let (status, headers) =
send_req(&mut self.handle, out, body, self.progress_bar_mode.clone())?;
debug!("response status: {}", status);
Ok(ApiResponse {
url,
status,
headers,
body: None,
Expand Down

0 comments on commit 632ab83

Please sign in to comment.