This commit is contained in:
xing 2022-10-06 21:53:54 +08:00
parent 31c53c9731
commit 1ea3cdff7b
2 changed files with 4 additions and 2 deletions

View File

@ -55,7 +55,7 @@ func Feed() func(ctx *gin.Context) {
common.PasswdProjectContent(&t)
}
l := ""
if t.CommentStatus == "open" {
if t.CommentStatus == "open" || t.CommentCount > 0 {
l = fmt.Sprintf("%s/p/%d#comments", models.Options["siteurl"], t.Id)
}
user := common.GetUser(c, t.PostAuthor)

View File

@ -26,7 +26,9 @@
<item>
<title>{{$v.PostTitle}}</title>
<link>{{$v.Link}}</link>
<comments>{{ $v.CommentLink}}</comments>
{{if $v.CommentLink}}
<comments>{{ $v.CommentLink}}</comments>
{{end}}
<dc:creator><![CDATA[{{$v.Username}}]]></dc:creator>
<pubDate>{{$v.Date}}</pubDate>
<category><![CDATA[{{$v.Cates}}]]></category>