Fix clippy.
format Build format has succeeded Details
rust-clippy Build rust-clippy has succeeded Details
rust-test Build rust-test has succeeded Details

main
Tom Alexander 4 months ago
parent 3b63bbdfde
commit 35cf675c87
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE

@ -32,7 +32,7 @@ render!(RenderRegularLink, IRegularLink, original, render_context, {
.unwrap_or_else(|| "".to_owned());
Ok(RenderRegularLink {
target: target,
target,
raw_link: original.raw_link.clone(),
children,
post_blank: original.post_blank,

@ -64,8 +64,8 @@ impl LinkTarget {
let post_id = parsed.host_str().map(str::to_owned);
let subpath = {
let subpath = parsed.path();
if subpath.starts_with('/') {
&subpath[1..]
if let Some(subpath) = subpath.strip_prefix('/') {
subpath
} else {
subpath
}

Loading…
Cancel
Save