mirror of
https://github.com/discourse/discourse.git
synced 2025-06-01 09:08:10 +08:00
FEATURE: Allow admins to control PWA display mode per user agent
This commit is contained in:
@ -19,7 +19,7 @@ class MetadataController < ApplicationController
|
||||
end
|
||||
file_info = get_file_info(logo)
|
||||
|
||||
display = request.user_agent =~ /iPad|iPhone/ ? 'browser' : 'standalone'
|
||||
display = Regexp.new(SiteSetting.pwa_display_browser_regex).match(request.user_agent) ? 'browser' : 'standalone'
|
||||
|
||||
manifest = {
|
||||
name: SiteSetting.title,
|
||||
|
Reference in New Issue
Block a user