Commit 6a9ac7d0 authored by gfyoung's avatar gfyoung

Enable some frozen string in ee/app

Enables frozen string in the following:

* ee/app/controllers/**/*.rb
* ee/app/finders/**/*.rb

Partially addresses gitlab-org/gitlab-ce/#47424.
parent 2c519c97
# frozen_string_literal: true
class Admin::AuditLogsController < Admin::ApplicationController class Admin::AuditLogsController < Admin::ApplicationController
before_action :check_license_admin_audit_log_available! before_action :check_license_admin_audit_log_available!
......
# frozen_string_literal: true
class Admin::EmailsController < Admin::ApplicationController class Admin::EmailsController < Admin::ApplicationController
def show def show
end end
......
# frozen_string_literal: true
class Admin::LicensesController < Admin::ApplicationController class Admin::LicensesController < Admin::ApplicationController
before_action :license, only: [:show, :download, :destroy] before_action :license, only: [:show, :download, :destroy]
before_action :require_license, only: [:download, :destroy] before_action :require_license, only: [:download, :destroy]
......
# frozen_string_literal: true
class Admin::PushRulesController < Admin::ApplicationController class Admin::PushRulesController < Admin::ApplicationController
before_action :check_push_rules_available! before_action :check_push_rules_available!
before_action :push_rule before_action :push_rule
......
# frozen_string_literal: true
module Boards module Boards
class MilestonesController < Boards::ApplicationController class MilestonesController < Boards::ApplicationController
def index def index
......
# frozen_string_literal: true
module Boards module Boards
class UsersController < Boards::ApplicationController class UsersController < Boards::ApplicationController
# Enumerates all users that are members of the board parent # Enumerates all users that are members of the board parent
......
# frozen_string_literal: true
module EE module EE
module InternalRedirect module InternalRedirect
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
module EE module EE
module IssuableActions module IssuableActions
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module IssuableCollections module IssuableCollections
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module LfsRequest module LfsRequest
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module ServiceParams module ServiceParams
ALLOWED_PARAMS_EE = [ ALLOWED_PARAMS_EE = [
......
# frozen_string_literal: true
module IssuableLinks module IssuableLinks
def index def index
render json: issues render json: issues
......
# frozen_string_literal: true
module SafeMirrorParams module SafeMirrorParams
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module Admin module Admin
module AppearancesController module AppearancesController
......
# frozen_string_literal: true
module EE module EE
module Admin module Admin
module ApplicationSettingsController module ApplicationSettingsController
......
# frozen_string_literal: true
module EE module EE
module Admin module Admin
module ApplicationsController module ApplicationsController
......
# frozen_string_literal: true
# rubocop:disable Gitlab/ModuleWithInstanceVariables # rubocop:disable Gitlab/ModuleWithInstanceVariables
module EE module EE
module Admin module Admin
......
# frozen_string_literal: true
# rubocop:disable Gitlab/ModuleWithInstanceVariables # rubocop:disable Gitlab/ModuleWithInstanceVariables
module EE module EE
module Admin module Admin
......
# frozen_string_literal: true
module EE::Admin::LogsController module EE::Admin::LogsController
include ::Gitlab::Utils::StrongMemoize include ::Gitlab::Utils::StrongMemoize
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
# rubocop:disable Gitlab/ModuleWithInstanceVariables # rubocop:disable Gitlab/ModuleWithInstanceVariables
module EE module EE
module Admin module Admin
......
# frozen_string_literal: true
# Shared actions between Groups::BoardsController and Projects::BoardsController # Shared actions between Groups::BoardsController and Projects::BoardsController
module EE module EE
module Boards module Boards
......
# frozen_string_literal: true
module EE module EE
module Boards module Boards
module ListsController module ListsController
......
# frozen_string_literal: true
module EE module EE
module ConfirmationsController module ConfirmationsController
include EE::Audit::Changes include EE::Audit::Changes
......
# frozen_string_literal: true
module EE module EE
module Groups module Groups
module ApplicationController module ApplicationController
......
# frozen_string_literal: true
module EE module EE
module Groups module Groups
module GroupMembersController module GroupMembersController
......
# frozen_string_literal: true
module EE module EE
module Groups module Groups
module MilestonesController module MilestonesController
......
# frozen_string_literal: true
module EE module EE
module GroupsController module GroupsController
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module Import module Import
module GithubController module GithubController
......
# frozen_string_literal: true
module EE module EE
module Ldap module Ldap
module OmniauthCallbacksController module OmniauthCallbacksController
......
# frozen_string_literal: true
module EE module EE
module OmniauthCallbacksController module OmniauthCallbacksController
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
module EE module EE
module PasswordsController module PasswordsController
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module ClustersController module ClustersController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module EnvironmentsController module EnvironmentsController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module GitHttpClientController module GitHttpClientController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module GitHttpController module GitHttpController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module LfsApiController module LfsApiController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module MergeRequests module MergeRequests
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module MergeRequestsController module MergeRequestsController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module MirrorsController module MirrorsController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module PipelinesController module PipelinesController
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module Prometheus module Prometheus
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module Settings module Settings
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module Settings module Settings
......
# frozen_string_literal: true
module EE module EE
module Projects module Projects
module VariablesController module VariablesController
......
# frozen_string_literal: true
module EE module EE
module ProjectsController module ProjectsController
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
module EE module EE
module RegistrationsController module RegistrationsController
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module SentNotificationsController module SentNotificationsController
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
module EE module EE
module SessionsController module SessionsController
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module UsersController module UsersController
def available_templates def available_templates
......
# frozen_string_literal: true
class Groups::AnalyticsController < Groups::ApplicationController class Groups::AnalyticsController < Groups::ApplicationController
before_action :group before_action :group
before_action :check_contribution_analytics_available! before_action :check_contribution_analytics_available!
......
# frozen_string_literal: true
class Groups::AuditEventsController < Groups::ApplicationController class Groups::AuditEventsController < Groups::ApplicationController
before_action :authorize_admin_group! before_action :authorize_admin_group!
before_action :check_audit_events_available! before_action :check_audit_events_available!
......
# frozen_string_literal: true
class Groups::AutocompleteSourcesController < Groups::ApplicationController class Groups::AutocompleteSourcesController < Groups::ApplicationController
before_action :load_autocomplete_service, except: [:members] before_action :load_autocomplete_service, except: [:members]
......
# frozen_string_literal: true
class Groups::BillingsController < Groups::ApplicationController class Groups::BillingsController < Groups::ApplicationController
before_action :authorize_admin_group! before_action :authorize_admin_group!
before_action :verify_namespace_plan_check_enabled before_action :verify_namespace_plan_check_enabled
......
# frozen_string_literal: true
class Groups::EpicIssuesController < Groups::EpicsController class Groups::EpicIssuesController < Groups::EpicsController
include IssuableLinks include IssuableLinks
......
# frozen_string_literal: true
class Groups::Epics::NotesController < Groups::ApplicationController class Groups::Epics::NotesController < Groups::ApplicationController
include NotesActions include NotesActions
include NotesHelper include NotesHelper
......
# frozen_string_literal: true
class Groups::EpicsController < Groups::ApplicationController class Groups::EpicsController < Groups::ApplicationController
include IssuableActions include IssuableActions
include IssuableCollections include IssuableCollections
......
# frozen_string_literal: true
class Groups::HooksController < Groups::ApplicationController class Groups::HooksController < Groups::ApplicationController
include HooksExecution include HooksExecution
......
# frozen_string_literal: true
class Groups::LdapGroupLinksController < Groups::ApplicationController class Groups::LdapGroupLinksController < Groups::ApplicationController
before_action :group before_action :group
before_action :require_ldap_enabled before_action :require_ldap_enabled
......
# frozen_string_literal: true
class Groups::LdapsController < Groups::ApplicationController class Groups::LdapsController < Groups::ApplicationController
before_action :group before_action :group
before_action :authorize_admin_group! before_action :authorize_admin_group!
......
# frozen_string_literal: true
class Groups::OmniauthCallbacksController < OmniauthCallbacksController class Groups::OmniauthCallbacksController < OmniauthCallbacksController
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
class Groups::PipelineQuotaController < Groups::ApplicationController class Groups::PipelineQuotaController < Groups::ApplicationController
before_action :authorize_admin_group! before_action :authorize_admin_group!
before_action :validate_shared_runner_minutes_support! before_action :validate_shared_runner_minutes_support!
......
# frozen_string_literal: true
module Groups module Groups
class RoadmapController < Groups::ApplicationController class RoadmapController < Groups::ApplicationController
include IssuableCollections include IssuableCollections
......
# frozen_string_literal: true
class Groups::SamlProvidersController < Groups::ApplicationController class Groups::SamlProvidersController < Groups::ApplicationController
before_action :require_top_level_group before_action :require_top_level_group
before_action :authorize_manage_saml! before_action :authorize_manage_saml!
......
# frozen_string_literal: true
class Groups::SsoController < Groups::ApplicationController class Groups::SsoController < Groups::ApplicationController
skip_before_action :group skip_before_action :group
before_action :unauthenticated_group before_action :unauthenticated_group
......
# frozen_string_literal: true
class Groups::TodosController < Groups::ApplicationController class Groups::TodosController < Groups::ApplicationController
include Gitlab::Utils::StrongMemoize include Gitlab::Utils::StrongMemoize
include TodosActions include TodosActions
......
# frozen_string_literal: true
class Oauth::GeoAuthController < ActionController::Base class Oauth::GeoAuthController < ActionController::Base
rescue_from Gitlab::Geo::OauthApplicationUndefinedError, with: :undefined_oauth_application rescue_from Gitlab::Geo::OauthApplicationUndefinedError, with: :undefined_oauth_application
rescue_from OAuth2::Error, with: :auth rescue_from OAuth2::Error, with: :auth
......
# frozen_string_literal: true
# This controller's role is to mimic and rewire the GitLab OAuth # This controller's role is to mimic and rewire the GitLab OAuth
# flow routes for Jira DVCS integration. # flow routes for Jira DVCS integration.
# See https://gitlab.com/gitlab-org/gitlab-ee/issues/2381 # See https://gitlab.com/gitlab-org/gitlab-ee/issues/2381
......
# frozen_string_literal: true
class OmniauthKerberosSpnegoController < ApplicationController class OmniauthKerberosSpnegoController < ApplicationController
include KerberosSpnegoHelper include KerberosSpnegoHelper
......
# frozen_string_literal: true
class Profiles::BillingsController < Profiles::ApplicationController class Profiles::BillingsController < Profiles::ApplicationController
before_action :verify_namespace_plan_check_enabled before_action :verify_namespace_plan_check_enabled
......
# frozen_string_literal: true
class Profiles::PipelineQuotaController < Profiles::ApplicationController class Profiles::PipelineQuotaController < Profiles::ApplicationController
def index def index
@namespace = current_user.namespace @namespace = current_user.namespace
......
# frozen_string_literal: true
class Profiles::SlacksController < Profiles::ApplicationController class Profiles::SlacksController < Profiles::ApplicationController
include ServicesHelper include ServicesHelper
......
# frozen_string_literal: true
class Projects::ApproverGroupsController < Projects::ApplicationController class Projects::ApproverGroupsController < Projects::ApplicationController
before_action :authorize_for_subject! before_action :authorize_for_subject!
......
# frozen_string_literal: true
class Projects::ApproversController < Projects::ApplicationController class Projects::ApproversController < Projects::ApplicationController
before_action :authorize_for_subject! before_action :authorize_for_subject!
......
# frozen_string_literal: true
class Projects::AuditEventsController < Projects::ApplicationController class Projects::AuditEventsController < Projects::ApplicationController
include LicenseHelper include LicenseHelper
......
# frozen_string_literal: true
class Projects::FeatureFlagsController < Projects::ApplicationController class Projects::FeatureFlagsController < Projects::ApplicationController
respond_to :html respond_to :html
......
# frozen_string_literal: true
module Projects module Projects
class IssueLinksController < Projects::ApplicationController class IssueLinksController < Projects::ApplicationController
include IssuableLinks include IssuableLinks
......
# frozen_string_literal: true
module Projects module Projects
module Packages module Packages
class PackagesController < ApplicationController class PackagesController < ApplicationController
......
# frozen_string_literal: true
class Projects::PathLocksController < Projects::ApplicationController class Projects::PathLocksController < Projects::ApplicationController
include PathLocksHelper include PathLocksHelper
include ExtractsPath include ExtractsPath
......
# frozen_string_literal: true
class Projects::PushRulesController < Projects::ApplicationController class Projects::PushRulesController < Projects::ApplicationController
include RepositorySettingsRedirect include RepositorySettingsRedirect
......
# frozen_string_literal: true
module Projects module Projects
module Security module Security
class DashboardController < Projects::ApplicationController class DashboardController < Projects::ApplicationController
......
# frozen_string_literal: true
class Projects::ServiceDeskController < Projects::ApplicationController class Projects::ServiceDeskController < Projects::ApplicationController
before_action :authorize_admin_project! before_action :authorize_admin_project!
......
# frozen_string_literal: true
module Projects module Projects
module Settings module Settings
class SlacksController < Projects::ApplicationController class SlacksController < Projects::ApplicationController
......
# frozen_string_literal: true
class Projects::VulnerabilityFeedbackController < Projects::ApplicationController class Projects::VulnerabilityFeedbackController < Projects::ApplicationController
before_action :vulnerability_feedback, only: [:destroy] before_action :vulnerability_feedback, only: [:destroy]
before_action :authorize_read_vulnerability_feedback!, only: [:index] before_action :authorize_read_vulnerability_feedback!, only: [:index]
......
# frozen_string_literal: true
class UnsubscribesController < ApplicationController class UnsubscribesController < ApplicationController
skip_before_action :authenticate_user! skip_before_action :authenticate_user!
......
# frozen_string_literal: true
module Boards module Boards
class MilestonesFinder class MilestonesFinder
def initialize(board, current_user = nil) def initialize(board, current_user = nil)
......
# frozen_string_literal: true
module Boards module Boards
class UsersFinder class UsersFinder
def initialize(board, current_user = nil) def initialize(board, current_user = nil)
......
# frozen_string_literal: true
module EE module EE
module IssuesFinder module IssuesFinder
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module LicenseTemplateFinder module LicenseTemplateFinder
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
module EE module EE
module NotesFinder module NotesFinder
extend ActiveSupport::Concern extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE module EE
module TemplateFinder module TemplateFinder
extend ::Gitlab::Utils::Override extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
class EpicsFinder < IssuableFinder class EpicsFinder < IssuableFinder
def self.scalar_params def self.scalar_params
@scalar_params ||= %i[ @scalar_params ||= %i[
......
# frozen_string_literal: true
module Geo module Geo
class AttachmentRegistryFinder < FileRegistryFinder class AttachmentRegistryFinder < FileRegistryFinder
def syncable def syncable
......
# frozen_string_literal: true
module Geo module Geo
class ExpireUploadsFinder class ExpireUploadsFinder
def find_project_uploads(project) def find_project_uploads(project)
......
# frozen_string_literal: true
module Geo module Geo
class FileRegistryFinder < RegistryFinder class FileRegistryFinder < RegistryFinder
# @abstract Subclass is expected to implement the declared methods # @abstract Subclass is expected to implement the declared methods
......
# frozen_string_literal: true
module Geo module Geo
class JobArtifactRegistryFinder < RegistryFinder class JobArtifactRegistryFinder < RegistryFinder
def count_syncable def count_syncable
......
# frozen_string_literal: true
module Geo module Geo
class LfsObjectRegistryFinder < FileRegistryFinder class LfsObjectRegistryFinder < FileRegistryFinder
def count_syncable def count_syncable
......
# frozen_string_literal: true
module Geo module Geo
class ProjectRegistryFinder < RegistryFinder class ProjectRegistryFinder < RegistryFinder
def count_projects def count_projects
......
# frozen_string_literal: true
module Geo module Geo
class RegistryFinder class RegistryFinder
attr_reader :current_node attr_reader :current_node
......
# frozen_string_literal: true
module Geo module Geo
class RepositoryVerificationFinder class RepositoryVerificationFinder
def initialize(shard_name: nil) def initialize(shard_name: nil)
......
# frozen_string_literal: true
class LogFinder class LogFinder
PER_PAGE = 25 PER_PAGE = 25
ENTITY_COLUMN_TYPES = { ENTITY_COLUMN_TYPES = {
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment