From b8a598e6a43fa65db23b88d3b3b281b5f2f7c2e0 Mon Sep 17 00:00:00 2001 From: wxiaoguang <wxiaoguang@gmail.com> Date: Fri, 1 Mar 2024 18:56:29 +0800 Subject: Refactor the "attachments" sub-template data key to RenderedContent (#29517) The value passed into "attachments" sub-template is from "RedneredContent", so use the same name for consistent. And it makes readers easy to know its data type. --- templates/repo/diff/comments.tmpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'templates/repo/diff') diff --git a/templates/repo/diff/comments.tmpl b/templates/repo/diff/comments.tmpl index e00487a22c..0bb577deba 100644 --- a/templates/repo/diff/comments.tmpl +++ b/templates/repo/diff/comments.tmpl @@ -63,7 +63,7 @@ <div id="issuecomment-{{.ID}}-raw" class="raw-content gt-hidden">{{.Content}}</div> <div class="edit-content-zone gt-hidden" data-update-url="{{$.root.RepoLink}}/comments/{{.ID}}" data-context="{{$.root.RepoLink}}" data-attachment-url="{{$.root.RepoLink}}/comments/{{.ID}}/attachments"></div> {{if .Attachments}} - {{template "repo/issue/view_content/attachments" dict "ctxData" $ "Attachments" .Attachments "Content" .RenderedContent}} + {{template "repo/issue/view_content/attachments" dict "ctxData" $ "Attachments" .Attachments "RenderedContent" .RenderedContent}} {{end}} </div> {{$reactions := .Reactions.GroupByType}} -- cgit v1.2.3