summaryrefslogtreecommitdiff
path: root/app/controllers/application_controller.rb
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-12-11 12:08:10 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2019-12-11 12:08:10 +0000
commitb86f474bf51e20d2db4cf0895d0a8e0894e31c08 (patch)
tree061d2a4c749924f5a35fe6199dd1d8982c4b0b27 /app/controllers/application_controller.rb
parent6b8040dc25fdc5fe614c3796a147517dd50bc7d8 (diff)
downloadgitlab-ce-b86f474bf51e20d2db4cf0895d0a8e0894e31c08.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/controllers/application_controller.rb')
-rw-r--r--app/controllers/application_controller.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb
index ee2b3741ac9..33ae778769a 100644
--- a/app/controllers/application_controller.rb
+++ b/app/controllers/application_controller.rb
@@ -16,6 +16,7 @@ class ApplicationController < ActionController::Base
include ConfirmEmailWarning
include Gitlab::Tracking::ControllerConcern
include Gitlab::Experimentation::ControllerConcern
+ include InitializesCurrentUserMode
before_action :authenticate_user!, except: [:route_not_found]
before_action :enforce_terms!, if: :should_enforce_terms?
@@ -41,7 +42,6 @@ class ApplicationController < ActionController::Base
protect_from_forgery with: :exception, prepend: true
helper_method :can?
- helper_method :current_user_mode
helper_method :import_sources_enabled?, :github_import_enabled?,
:gitea_import_enabled?, :github_import_configured?,
:gitlab_import_enabled?, :gitlab_import_configured?,
@@ -546,10 +546,6 @@ class ApplicationController < ActionController::Base
end
end
- def current_user_mode
- @current_user_mode ||= Gitlab::Auth::CurrentUserMode.new(current_user)
- end
-
# A user requires a role and have the setup_for_company attribute set when they are part of the experimental signup
# flow (executed by the Growth team). Users are redirected to the welcome page when their role is required and the
# experiment is enabled for the current user.