Skip to content

Commit

Permalink
Fix clippy issues for 0.2.1 release
Browse files Browse the repository at this point in the history
  • Loading branch information
mksh committed Mar 5, 2024
1 parent d7f5a7e commit 0a75342
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,8 @@ impl VCRMiddleware {
for interaction in iteractions {
if interaction.request == req {
return Some(interaction.response.clone());
} else if let Some(diff) = diff_log.as_mut() {
}
if let Some(diff) = diff_log.as_mut() {
diff.push_str(&format!(
"Did not match {method:?} to {uri}:\n",
method = interaction.request.method,
Expand Down Expand Up @@ -313,7 +314,7 @@ impl VCRMiddleware {
if !interaction.request.headers.contains_key(got_header_name) {
let got = self.header_values_to_string(Some(got_header_values));
diff.push_str(&format!(" {}:\n", got_header_name));
diff.push_str(&format!(" recorded: <MISSING>\n"));
diff.push_str(" recorded: <MISSING>\n");
diff.push_str(&format!(" got: \"{}\"\n", got));
}
}
Expand All @@ -326,7 +327,7 @@ impl VCRMiddleware {
));
diff.push_str(&format!(" got: \"{}\"\n", req.body.string));
}
diff.push_str("\n");
diff.push('\n');
}
}
if let Some(diff) = diff_log {
Expand Down

0 comments on commit 0a75342

Please sign in to comment.