From 0c0b0e42123e86e750fc7446608ff09e3d62c5fa Mon Sep 17 00:00:00 2001 From: freamon Date: Fri, 25 Oct 2024 08:31:47 +0000 Subject: [PATCH] post soft-deletion: hide links in user profile replies section that'll likely 404 --- app/templates/post/_post_reply_teaser.html | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/app/templates/post/_post_reply_teaser.html b/app/templates/post/_post_reply_teaser.html index c82612b3..29ceb0f2 100644 --- a/app/templates/post/_post_reply_teaser.html +++ b/app/templates/post/_post_reply_teaser.html @@ -14,7 +14,11 @@ {% if teaser -%}
- reply to: {{ post_reply.post.title | truncate(80, True) }} + {% if post_reply.post.deleted: -%} + reply to: [deleted post] + {% else -%} + reply to: {{ post_reply.post.title | truncate(80, True) }} + {% endif -%} in {{ render_communityname(post_reply.post.community) }}
@@ -53,7 +57,11 @@
{% if post_reply.post.comments_enabled -%} - reply + {% if not post_reply.post.deleted and not post_reply.deleted -%} + reply + {% else -%} + reply + {% endif -%} {% endif -%}
{% with comment=post_reply, community=post_reply.post.community -%} @@ -74,7 +82,9 @@ {% endwith -%} {% endif -%}
- + {% if not post_reply.post.deleted -%} + + {% endif -%}
{% if not post_reply.author.indexable -%}{% endif -%} {% if collapsed -%}