Commit 5888e0cc authored by gfyoung's avatar gfyoung

Enable some frozen string in ee/app

Enables frozen string in the following:

* ee/app/policies/**/*.rb
* ee/app/presenters/**/*.rb
* ee/app/serializers/**/*.rb
* ee/app/services/**/*.rb
* ee/app/uploaders/**/*.rb
* ee/app/validators/**/*.rb
* ee/app/workers/**/*.rb

Partially addresses gitlab-org/gitlab-ce/#47424.
parent 5f138cdd
# frozen_string_literal: true
module EE
module BoardsResponses
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module BasePolicy
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module GroupPolicy
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module MergeRequestPolicy
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module ProjectPolicy
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module ProtectedBranchPolicy
extend ActiveSupport::Concern
......
# frozen_string_literal: true
class EpicPolicy < BasePolicy
delegate { @subject.group }
......
# frozen_string_literal: true
class SamlProviderPolicy < BasePolicy
rule { ~anonymous }.enable :sign_in_with_saml_provider
end
# frozen_string_literal: true
class AuditEventPresenter < Gitlab::View::Presenter::Simple
presents :audit_event
......
# frozen_string_literal: true
module EE
module Ci
module PipelinePresenter
......
# frozen_string_literal: true
module EE
module GroupMemberPresenter
def group_sso?
......
# frozen_string_literal: true
module EE
module MemberPresenter
def can_update?
......
# frozen_string_literal: true
module EE
module MergeRequestPresenter
include ::VisibleApprovable
......
# frozen_string_literal: true
module EE
module ProjectMemberPresenter
def group_sso?
......
# frozen_string_literal: true
module EE
module EnvironmentEntity
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module IssuableSidebarEntity
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module IssueSidebarEntity
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module MergeRequestWidgetEntity
include ::API::Helpers::RelatedResourcesHelpers
......
# frozen_string_literal: true
module EE
module ProjectMirrorEntity
extend ActiveSupport::Concern
......
# frozen_string_literal: true
module EE
module VariableEntity
extend ActiveSupport::Concern
......
# frozen_string_literal: true
class EpicBaseEntity < Grape::Entity
include RequestAwareEntity
include EntityDateHelper
......
# frozen_string_literal: true
class EpicEntity < IssuableEntity
expose :group_id
expose :group_name do |epic|
......
# frozen_string_literal: true
class EpicNoteEntity < NoteEntity
expose :toggle_award_path, if: -> (note, _) { note.emoji_awardable? } do |note|
toggle_award_emoji_group_epic_note_path(note.noteable.group, note.noteable, note)
......
# frozen_string_literal: true
class EpicNoteSerializer < BaseSerializer
entity EpicNoteEntity
end
# frozen_string_literal: true
class EpicSerializer < BaseSerializer
entity EpicEntity
end
# frozen_string_literal: true
class FileLockEntity < Grape::Entity
expose :user, using: API::Entities::UserSafe
end
# frozen_string_literal: true
class GeoNodeStatusSerializer < BaseSerializer
entity EE::API::Entities::GeoNodeStatus
end
# frozen_string_literal: true
class GeoProjectRegistryEntity < Grape::Entity
expose :project_id
expose :last_repository_synced_at
......
# frozen_string_literal: true
class GeoProjectRegistrySerializer < BaseSerializer
entity GeoProjectRegistryEntity
end
# frozen_string_literal: true
class GroupAnalyticsSerializer < BaseSerializer
entity UserAnalyticsEntity
end
# frozen_string_literal: true
class MilestoneSerializer < BaseSerializer
entity API::Entities::Milestone
end
# frozen_string_literal: true
class NamespaceEntity < Grape::Entity
expose :id, :name, :path, :kind, :full_path, :parent_id
end
# frozen_string_literal: true
class PrometheusAlertEntity < Grape::Entity
include RequestAwareEntity
......
# frozen_string_literal: true
class PrometheusAlertSerializer < BaseSerializer
entity PrometheusAlertEntity
end
# frozen_string_literal: true
class PrometheusMetricEntity < Grape::Entity
include RequestAwareEntity
......
# frozen_string_literal: true
class PrometheusMetricSerializer < BaseSerializer
entity PrometheusMetricEntity
end
# frozen_string_literal: true
class RolloutStatusEntity < Grape::Entity
include RequestAwareEntity
......
# frozen_string_literal: true
class StorageShardEntity < Grape::Entity
expose :name
end
# frozen_string_literal: true
class StorageShardSerializer < BaseSerializer
entity StorageShardEntity
end
# frozen_string_literal: true
class TriggeredPipelineEntity < Grape::Entity
include RequestAwareEntity
......
# frozen_string_literal: true
class UserAnalyticsEntity < Grape::Entity
include RequestAwareEntity
......
# frozen_string_literal: true
class Vulnerabilities::OccurrenceSerializer < BaseSerializer
include WithPagination
......
# frozen_string_literal: true
class VulnerabilitySummarySerializer < BaseSerializer
entity VulnerabilitySummaryEntity
end
# frozen_string_literal: true
module Boards
class DestroyService < Boards::BaseService
def execute(board)
......
# frozen_string_literal: true
module Boards
class UpdateService < Boards::BaseService
def execute(board)
......
# frozen_string_literal: true
module CiCd
class GithubIntegrationSetupService
attr_reader :project
......
# frozen_string_literal: true
module CiCd
class GithubSetupService
attr_reader :project
......
# frozen_string_literal: true
module CiCd
class SetupProject < ::BaseService
def execute
......
# frozen_string_literal: true
class ClearNamespaceSharedRunnersMinutesService < BaseService
def initialize(namespace)
@namespace = namespace
......
# frozen_string_literal: true
module Clusters
module Applications
class CheckUpgradeProgressService < BaseHelmService
......
# frozen_string_literal: true
module Clusters
module Applications
class PrometheusUpdateService < BaseHelmService
......
# frozen_string_literal: true
module Clusters
module Applications
class ScheduleUpdateService
......
# frozen_string_literal: true
# Concern that encapsulates logic to remove all
# approvers in a project that were not added during
# the current transaction
......
# frozen_string_literal: true
module ValidatesClassificationLabel
def validate_classification_label(record, attribute_name)
return unless EE::Gitlab::ExternalAuthorization.enabled?
......
# frozen_string_literal: true
module EE
module ApplicationSettings
module UpdateService
......
# frozen_string_literal: true
module EE
module Applications
# rubocop:disable Gitlab/ModuleWithInstanceVariables
......
# frozen_string_literal: true
module EE
module AuditEventService
# rubocop:disable Gitlab/ModuleWithInstanceVariables
......
# frozen_string_literal: true
module EE
module BaseCountService
extend ::Gitlab::Utils::Override
......
# frozen_string_literal: true
module EE
module Boards
module BaseService
......
# frozen_string_literal: true
module EE
module Boards
module CreateService
......
# frozen_string_literal: true
module EE
module Boards
module Issues
......
# frozen_string_literal: true
module EE
module Boards
module Issues
......
# frozen_string_literal: true
module EE
module Boards
module Issues
......
# frozen_string_literal: true
module EE
module Boards
module ListService
......
# frozen_string_literal: true
module EE
module Boards
module Lists
......
# frozen_string_literal: true
module EE
module Boards
module Lists
......
# frozen_string_literal: true
module EE
module Ci
# RegisterJobService EE mixin
......
# frozen_string_literal: true
module EE
module Clusters
module Applications
......
# frozen_string_literal: true
module EE
module Clusters
module CreateService
......
# frozen_string_literal: true
module EE
module Commits
module CreateService
......
# frozen_string_literal: true
module EE
module Emails
module BaseService
......
# frozen_string_literal: true
module EE
module Emails
module CreateService
......
# frozen_string_literal: true
module EE
module Emails
module DestroyService
......
# frozen_string_literal: true
module EE
module Groups
module CreateService
......
# frozen_string_literal: true
module EE
module Groups
module DestroyService
......
# frozen_string_literal: true
module EE
module Groups
module UpdateService
......
# frozen_string_literal: true
module EE
module Issuable
module CommonSystemNotesService
......
# frozen_string_literal: true
module EE
module IssuableBaseService
private
......
# frozen_string_literal: true
module EE
module Issues
module BuildService
......
# frozen_string_literal: true
module EE
module Issues
module MoveService
......
# frozen_string_literal: true
module EE
module Keys
module CreateService
......
# frozen_string_literal: true
module EE
module Keys
module DestroyService
......
# frozen_string_literal: true
module EE
module Lfs
module LockFileService
......
# frozen_string_literal: true
module EE
module Lfs
module UnlockFileService
......
# frozen_string_literal: true
module EE
module Members
module ApproveAccessRequestService
......
# frozen_string_literal: true
module EE
module Members
module CreateService
......
# frozen_string_literal: true
module EE
module Members
module DestroyService
......
# frozen_string_literal: true
module EE
module Members
module UpdateService
......
# frozen_string_literal: true
module EE
module MergeRequests
module BaseService
......
# frozen_string_literal: true
module EE
module MergeRequests
module BuildService
......
# frozen_string_literal: true
module EE
module MergeRequests
module MergeService
......
# frozen_string_literal: true
module EE
module MergeRequests
module RefreshService
......
# frozen_string_literal: true
module EE
module MergeRequests
module UpdateService
......
# frozen_string_literal: true
module EE
module Milestones
module PromoteService
......
# frozen_string_literal: true
module EE
module Notes
module BuildService
......
# frozen_string_literal: true
require 'ee/gitlab/service_desk'
module EE
......
# frozen_string_literal: true
module EE
module Projects
module CreateFromTemplateService
......
# frozen_string_literal: true
module EE
module Projects
module CreateService
......
# frozen_string_literal: true
module EE
module Projects
module DestroyService
......
# frozen_string_literal: true
module EE
module Projects
module GitlabProjectsImportService
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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