diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-09 03:08:42 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-09-09 03:08:42 +0300 |
commit | f0809fbc2c72869130134d829232153a2e8193c6 (patch) | |
tree | c1f6e9c100e9d57246144e5a8a140f44ed195ad5 /app/helpers/application_helper.rb | |
parent | 459939f27fe77e90d7ba2b1d6c0aff59ff38e336 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/helpers/application_helper.rb')
-rw-r--r-- | app/helpers/application_helper.rb | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb index 09f21e4b727..a81225c8954 100644 --- a/app/helpers/application_helper.rb +++ b/app/helpers/application_helper.rb @@ -4,6 +4,8 @@ require 'digest/md5' require 'uri' module ApplicationHelper + include StartupCssHelper + # See https://docs.gitlab.com/ee/development/ee_features.html#code-in-app-views # rubocop: disable CodeReuse/ActiveRecord def render_if_exists(partial, locals = {}) @@ -235,10 +237,6 @@ module ApplicationHelper "#{request.path}?#{options.compact.to_param}" end - def use_startup_css? - (Feature.enabled?(:startup_css) || params[:startup_css] == 'true' || cookies['startup_css'] == 'true') && !Rails.env.test? - end - def stylesheet_link_tag_defer(path) if use_startup_css? stylesheet_link_tag(path, media: "print", crossorigin: ActionController::Base.asset_host ? 'anonymous' : nil) |