Skip to content

Commit

Permalink
Merge pull request #266 from helsing-ai/rene/issue-128
Browse files Browse the repository at this point in the history
Remove unnecessary From<ValidatedResponse> for reqwest::Response
  • Loading branch information
tomkarw committed Aug 9, 2024
2 parents 53671d7 + 1dc0231 commit a9df7a0
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/registry/artifactory.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ impl Artifactory {
.new_request(Method::GET, search_query_url)
.send()
.await?;
let response: reqwest::Response = response.into();
let response: reqwest::Response = response.0;

let headers = response.headers();
let content_type = headers
Expand Down Expand Up @@ -178,7 +178,7 @@ impl Artifactory {

let response = self.new_request(Method::GET, artifact_url).send().await?;

let response: reqwest::Response = response.into();
let response: reqwest::Response = response.0;

let headers = response.headers();
let content_type = headers
Expand Down Expand Up @@ -273,12 +273,6 @@ impl RequestBuilder {

struct ValidatedResponse(reqwest::Response);

impl From<ValidatedResponse> for reqwest::Response {
fn from(value: ValidatedResponse) -> Self {
value.0
}
}

impl TryFrom<Response> for ValidatedResponse {
type Error = miette::Report;

Expand Down

0 comments on commit a9df7a0

Please sign in to comment.