mirror of
https://gitea.phreedom.club/localhost_frssoft/bloat.git
synced 2024-11-05 06:33:01 +00:00
Fix mentions
This commit is contained in:
parent
da44fafe92
commit
8236f08c18
@ -246,15 +246,22 @@ func (svc *service) ServeThreadPage(ctx context.Context, client io.Writer, c *ma
|
||||
return
|
||||
}
|
||||
|
||||
var content string
|
||||
if reply {
|
||||
content += status.Account.Acct + " "
|
||||
for _, m := range status.Mentions {
|
||||
content += m.Acct + " "
|
||||
}
|
||||
u, err := c.GetAccountCurrentUser(ctx)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
fmt.Println("content", content)
|
||||
var content string
|
||||
if reply {
|
||||
if u.ID != status.Account.ID {
|
||||
content += "@" + status.Account.Acct + " "
|
||||
}
|
||||
for _, m := range status.Mentions {
|
||||
if u.ID != m.ID {
|
||||
content += "@" + m.Acct + " "
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
data := renderer.NewThreadPageTemplateData(status, context, reply, id, content)
|
||||
err = svc.renderer.RenderThreadPage(ctx, client, data)
|
||||
|
Loading…
Reference in New Issue
Block a user