chore: fix update to 0.4.40 with absolute links via site-url
This commit is contained in:
parent
e1235853e3
commit
7ad069e632
@ -53,8 +53,12 @@ impl HtmlHandlebars {
|
||||
ctx.data
|
||||
.insert("git_repository_edit_url".to_owned(), json!(edit_url));
|
||||
}
|
||||
|
||||
let content = utils::render_markdown(&ch.content, ctx.html_config.smart_punctuation());
|
||||
let content = if let Some(site_url) = &ctx.html_config.site_url {
|
||||
let ch = ch.content.clone().replace("](./",&format!("]({}",site_url));
|
||||
utils::render_markdown(&ch, ctx.html_config.smart_punctuation())
|
||||
} else {
|
||||
utils::render_markdown(&ch.content, ctx.html_config.smart_punctuation())
|
||||
};
|
||||
|
||||
let fixed_content = utils::render_markdown_with_path(
|
||||
&ch.content,
|
||||
|
Loading…
Reference in New Issue
Block a user