From 96c2cbe1850f95806cccb6f47a7739eb9c2ac860 Mon Sep 17 00:00:00 2001 From: "Gabriel A. Giovanini" Date: Sat, 11 Jun 2022 00:18:54 +0200 Subject: fix: Fix blog post timestamps For some the timestamp got messed up. Now they should be restored properly as well the `locustfile.py` pointing to the right endpoints. --- src/blog.rs | 4 +++- src/router.rs | 2 -- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/blog.rs b/src/blog.rs index eaa314a..a1586f8 100644 --- a/src/blog.rs +++ b/src/blog.rs @@ -18,7 +18,9 @@ pub fn read_assets() -> Vec { fn get_file_content(path: &str) -> String { let buffer = PostAsset::get(path).unwrap().data.into_owned(); let md = String::from_utf8(buffer).unwrap(); - let parser = Parser::new_ext(&md, Options::empty()); + let mut options = Options::empty(); + options.insert(Options::ENABLE_FOOTNOTES); + let parser = Parser::new_ext(&md, options); let mut html_output = &mut String::new(); html::push_html(&mut html_output, parser); return html_output.to_string(); diff --git a/src/router.rs b/src/router.rs index c196ab8..3227d66 100644 --- a/src/router.rs +++ b/src/router.rs @@ -1,5 +1,3 @@ -use std::borrow::Borrow; - use crate::assets::PostAsset; use regex::Regex; -- cgit v1.2.3