1
Fork 0

Use more let chain

This commit is contained in:
Guillaume Gomez 2023-02-15 11:30:14 +01:00
parent 9bb6e60d1f
commit 86fd5a1b44
16 changed files with 223 additions and 254 deletions

View file

@ -709,11 +709,9 @@ pub(crate) fn href_with_root_path(
}
}
};
if !is_remote {
if let Some(root_path) = root_path {
let root = root_path.trim_end_matches('/');
url_parts.push_front(root);
}
if !is_remote && let Some(root_path) = root_path {
let root = root_path.trim_end_matches('/');
url_parts.push_front(root);
}
debug!(?url_parts);
match shortty {