Skip to content

Commit a8ab8a8

Browse files
committed
fix internal link finding for database_query, atom_movable
1 parent 5c96d7e commit a8ab8a8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tools/od_ref_bot/src/main.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ fn format_body(body: &str, data: &Data) -> String {
264264
let mut replaced_body = body.to_string();
265265

266266
let link_finder_regex =
267-
Regex::new(r##"\{\{ *?([a-zA-Z]*)\(((var|proc)="([a-zA-Z]*?)")? ?\).*?\}\}"##).unwrap();
267+
Regex::new(r##"\{\{ *?([a-zA-Z_]*)\(((var|proc)="([a-zA-Z]*?)")? ?\).*?\}\}"##).unwrap();
268268

269269
for capture in link_finder_regex.captures_iter(body) {
270270
let original = capture.get(0).unwrap().as_str();
@@ -310,7 +310,7 @@ fn format_body(body: &str, data: &Data) -> String {
310310

311311
new_body = tag_cleaner_regex.replace_all(&new_body, "").to_string();
312312
new_body = new_body.replace("```dm", "```js");
313-
new_body.replace("\n\n", "")
313+
new_body.replace("\n\n\n", "\n")
314314
}
315315

316316
/// Converts the internal Zola page structure into something we can link to.

0 commit comments

Comments
 (0)