mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FEATURE: Upload Site Settings. (#6573)
This commit is contained in:
@@ -13,10 +13,14 @@ class MetadataController < ApplicationController
|
||||
private
|
||||
|
||||
def default_manifest
|
||||
logo = SiteSetting.large_icon_url.presence || SiteSetting.logo_small_url.presence || SiteSetting.apple_touch_icon_url.presence
|
||||
logo = SiteSetting.site_large_icon_url.presence ||
|
||||
SiteSetting.site_logo_small_url.presence ||
|
||||
SiteSetting.site_apple_touch_icon_url.presence
|
||||
|
||||
if !logo
|
||||
logo = path('/images/d-logo-sketch-small.png')
|
||||
logo = '/images/d-logo-sketch-small.png'
|
||||
end
|
||||
|
||||
file_info = get_file_info(logo)
|
||||
|
||||
display = Regexp.new(SiteSetting.pwa_display_browser_regex).match(request.user_agent) ? 'browser' : 'standalone'
|
||||
@@ -30,7 +34,7 @@ class MetadataController < ApplicationController
|
||||
theme_color: "##{ColorScheme.hex_for_name('header_background', view_context.scheme_id)}",
|
||||
icons: [
|
||||
{
|
||||
src: logo,
|
||||
src: UrlHelper.absolute(logo),
|
||||
sizes: file_info[:size],
|
||||
type: file_info[:type]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user