From 516e791ad6eb73ce3cc025b47318e9a6beb1cc6e Mon Sep 17 00:00:00 2001 From: slonkazoid Date: Sun, 26 May 2024 20:23:40 +0300 Subject: [PATCH] advertise rss --- src/main.rs | 2 ++ templates/index.html | 3 +++ 2 files changed, 5 insertions(+) diff --git a/src/main.rs b/src/main.rs index 4fcc1ac..ff09d4c 100644 --- a/src/main.rs +++ b/src/main.rs @@ -56,6 +56,7 @@ struct IndexTemplate { title: String, description: String, posts: Vec, + rss: bool, } #[derive(Template)] @@ -87,6 +88,7 @@ async fn index( title: state.config.title.clone(), description: state.config.description.clone(), posts, + rss: state.config.rss.enable, }) } diff --git a/templates/index.html b/templates/index.html index 591c008..ee96b71 100644 --- a/templates/index.html +++ b/templates/index.html @@ -9,6 +9,9 @@ {{ title }} + {% if rss %} + + {% endif %}