SECURITY: banner-info (#17071)

This commit is contained in:
Blake Erickson
2022-06-13 11:10:21 -06:00
committed by GitHub
parent 6650218e3d
commit ae6a907943
2 changed files with 50 additions and 0 deletions

View File

@ -676,6 +676,7 @@ class ApplicationController < ActionController::Base
def banner_json
json = ApplicationController.banner_json_cache["json"]
return "{}" if !current_user && SiteSetting.login_required?
unless json
topic = Topic.where(archetype: Archetype.banner).first