0
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2026-08-06 05:42:36 +08:00
discourse/lib/configurable_urls.rb
Bianca Nenciu 5fc1586abf
PERF: Cache ToS and Privacy Policy paths (#21860)
Checking if the topic exists happened often and that can cause
performance issues.
2023-06-07 21:31:20 +03:00

15 lines
272 B
Ruby
Vendored

# frozen_string_literal: true
module ConfigurableUrls
def faq_path
SiteSetting.faq_url.blank? ? "#{Discourse.base_path}/faq" : SiteSetting.faq_url
end
def tos_url
Discourse.tos_url
end
def privacy_policy_url
Discourse.privacy_policy_url
end
end