From 29c9bda4112241746fe50327ca404353a42c1a7b Mon Sep 17 00:00:00 2001 From: Butter Cat Date: Sat, 21 Mar 2026 12:49:55 -0400 Subject: [PATCH] Prevent an out of bounds from trying to access comments[0].author.name when there are no comments --- templates/post.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/post.html b/templates/post.html index adbe6d6d..a41d9eb0 100644 --- a/templates/post.html +++ b/templates/post.html @@ -2,7 +2,7 @@ {% import "utils.html" as utils %} {% block title %} - {% if single_thread %} + {% if single_thread && comments.len() > 0 %} {{ comments[0].author.name }} comments on {{ post.title }} - r/{{ post.community }} {% else %} {{ post.title }} - r/{{ post.community }}