From 637530e3ef16a74076351ba6e13bbccecda01ac5 Mon Sep 17 00:00:00 2001 From: kilo Date: Thu, 9 Nov 2017 18:28:38 +0100 Subject: [PATCH] change name of variable used in comment loop for clarity purposes --- templates/site/torrents/view.jet.html | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/templates/site/torrents/view.jet.html b/templates/site/torrents/view.jet.html index 586058e7..d7390f9b 100644 --- a/templates/site/torrents/view.jet.html +++ b/templates/site/torrents/view.jet.html @@ -212,23 +212,23 @@ {{idx := 1}} {{previousComment := ""}} {{previousUser := 0}} - {{range index, element := Torrent.Comments}} - {{if previousComment != element.Content || previousUser != element.UserID || element.UserID == 0}} + {{range _, comment := Torrent.Comments}} + {{if previousComment != comment.Content || previousUser != comment.UserID || comment.UserID == 0}}
{{idx}} - {{formatDate(element.Date, false)}} + {{formatDate(comment.Date, false)}} - - {{if element.UserID > 0}}{{element.Username}}{{if element.UserStatus != ""}}{{T(element.UserStatus)}}{{end}}{{else}} + + {{if comment.UserID > 0}}{{comment.Username}}{{if comment.UserStatus != ""}}{{T(comment.UserStatus)}}{{end}}{{else}} れんちょん{{end}} -
{{element.Content|raw}}
+
{{comment.Content|raw}}
{{idx = idx + 1}} {{end}} - {{previousComment = element.Content}} - {{previousUser = element.UserID}} + {{previousComment = comment.Content}} + {{previousUser = comment.UserID}} {{end}} {{ if len(Torrent.Comments) == 0 }}

{{ T("torrent_no_comments") }}