aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lib.rs8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/lib.rs b/src/lib.rs
index c5b1016..bf6bd15 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -165,7 +165,13 @@ pub fn module(router: &mut windmark::Router) {
router.set_footer(Box::new(|_| {
format!(
- "## COMMENTS\n=> /api/post-comment Make a comment!\n{}",
+ "## COMMENTS ({}/{})\n=> /api/post-comment Make a comment!\n{}",
+ if let Ok(comments) = COMMENTS.lock() {
+ (*comments).len().to_string()
+ } else {
+ "?".to_string()
+ },
+ MAX_COMMENTS.load(Ordering::SeqCst),
if let Ok(comments) = COMMENTS.lock() {
let comments = (*comments)
.iter()