Skip to content

Commit

Permalink
Fix linter warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
rvanasa committed Jan 9, 2024
1 parent 6661b9e commit d4d891a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/http.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ pub async fn do_http_request_with_metrics(
match ic_cdk::api::management_canister::http_request::http_request(request, cycles_cost).await {
Ok((response,)) => {
let status: u32 = response.status.0.clone().try_into().unwrap_or(0);
if status < 200 || status >= 300 {
if !(200..300).contains(&status) {
add_metric_entry!(err_http_response, (rpc_method.clone(), rpc_host.clone()), 1);
}
add_metric_entry!(responses, (rpc_method, rpc_host), 1);
Expand Down

0 comments on commit d4d891a

Please sign in to comment.