fix clippy lints

This commit is contained in:
Martin Algesten
2020-01-07 07:55:03 +01:00
committed by Martin Algesten
parent a6f64188dc
commit 4b9cfe2b67
3 changed files with 12 additions and 21 deletions

View File

@@ -338,7 +338,7 @@ fn save_cookies(unit: &Unit, resp: &Response) {
if let Some(add_jar) = state.as_mut().map(|state| &mut state.jar) {
for raw_cookie in cookies.iter() {
let to_parse = if raw_cookie.to_lowercase().contains("domain=") {
raw_cookie.to_string()
(*raw_cookie).to_string()
} else {
let host = &unit.url.host_str().unwrap_or(DEFAULT_HOST).to_string();
format!("{}; Domain={}", raw_cookie, host)