Module: Impersonation

Includes:
Gitlab::Utils::StrongMemoize
Included in:
ApplicationController
Defined in:
app/controllers/concerns/impersonation.rb

Constant Summary collapse

SESSION_KEYS_TO_DELETE =
%w[
  github_access_token gitea_access_token gitlab_access_token
  bitbucket_token bitbucket_refresh_token bitbucket_server_personal_access_token
  bulk_import_gitlab_access_token fogbugz_token cloud_platform_access_token
].freeze

Instance Method Summary collapse

Instance Method Details

#current_userObject



12
13
14
15
16
17
18
# File 'app/controllers/concerns/impersonation.rb', line 12

def current_user
  user = super

  user.impersonator = impersonator if impersonator

  user
end