mirror of
https://github.com/discourse/discourse.git
synced 2025-05-28 13:51:18 +08:00
SECURITY: Show only visible tags in metadata
Currently, the topic metadata show both public and private tags whereas only visible ones should be exposed.
This commit is contained in:

committed by
Loïc Guitaut

parent
5dbdcb3f23
commit
a9f2c6db64
@ -1231,7 +1231,7 @@ class TopicsController < ApplicationController
|
||||
|
||||
respond_to do |format|
|
||||
format.html do
|
||||
@tags = SiteSetting.tagging_enabled ? @topic_view.topic.tags : []
|
||||
@tags = SiteSetting.tagging_enabled ? @topic_view.topic.tags.visible(guardian) : []
|
||||
@breadcrumbs = helpers.categories_breadcrumb(@topic_view.topic) || []
|
||||
@description_meta =
|
||||
@topic_view.topic.excerpt.present? ? @topic_view.topic.excerpt : @topic_view.summary
|
||||
|
Reference in New Issue
Block a user