diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-09-13 13:26:31 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-09-13 13:26:31 +0000 |
commit | b7dfe2ae4054aa40e15182fd3c6cb7dd39f131db (patch) | |
tree | 5ab080ca9cadeb6cd9578bf301e4e9e8810bed9e /app/services | |
parent | 25cb337cf12438169f1b14bc5dace8a06a7356e3 (diff) | |
download | gitlab-ce-b7dfe2ae4054aa40e15182fd3c6cb7dd39f131db.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/services')
100 files changed, 200 insertions, 0 deletions
diff --git a/app/services/application_settings/update_service.rb b/app/services/application_settings/update_service.rb index e06a87c4763..6400b182715 100644 --- a/app/services/application_settings/update_service.rb +++ b/app/services/application_settings/update_service.rb @@ -78,3 +78,5 @@ module ApplicationSettings end end end + +ApplicationSettings::UpdateService.prepend_if_ee('EE::ApplicationSettings::UpdateService') diff --git a/app/services/applications/create_service.rb b/app/services/applications/create_service.rb index dff0d9696f8..d71174d1393 100644 --- a/app/services/applications/create_service.rb +++ b/app/services/applications/create_service.rb @@ -15,3 +15,5 @@ module Applications end end end + +Applications::CreateService.prepend_if_ee('EE::Applications::CreateService') diff --git a/app/services/audit_event_service.rb b/app/services/audit_event_service.rb index 22ade0b0658..40761ee97d2 100644 --- a/app/services/audit_event_service.rb +++ b/app/services/audit_event_service.rb @@ -47,3 +47,5 @@ class AuditEventService SecurityEvent.create(base_payload.merge(details: @details)) end end + +AuditEventService.prepend_if_ee('EE::AuditEventService') diff --git a/app/services/auto_merge_service.rb b/app/services/auto_merge_service.rb index 053c6d71fbb..eee227be202 100644 --- a/app/services/auto_merge_service.rb +++ b/app/services/auto_merge_service.rb @@ -60,3 +60,5 @@ class AutoMergeService < BaseService self.class.get_service_class(strategy)&.new(project, current_user, params) end end + +AutoMergeService.prepend_if_ee('EE::AutoMergeService') diff --git a/app/services/base_count_service.rb b/app/services/base_count_service.rb index cfad2dd9265..2936bdae16e 100644 --- a/app/services/base_count_service.rb +++ b/app/services/base_count_service.rb @@ -48,3 +48,5 @@ class BaseCountService Rails.cache.write(key, block_given? ? yield : uncached_count, raw: raw?) end end + +BaseCountService.prepend_if_ee('EE::BaseCountService') diff --git a/app/services/boards/base_service.rb b/app/services/boards/base_service.rb index 205db47888e..439a5c06223 100644 --- a/app/services/boards/base_service.rb +++ b/app/services/boards/base_service.rb @@ -10,3 +10,5 @@ module Boards end end end + +Boards::BaseService.prepend_if_ee('EE::Boards::BaseService') diff --git a/app/services/boards/create_service.rb b/app/services/boards/create_service.rb index dd9358913fd..1a5dc790c41 100644 --- a/app/services/boards/create_service.rb +++ b/app/services/boards/create_service.rb @@ -24,3 +24,5 @@ module Boards end end end + +Boards::CreateService.prepend_if_ee('EE::Boards::CreateService') diff --git a/app/services/boards/issues/create_service.rb b/app/services/boards/issues/create_service.rb index bd045e18b8d..1769966a049 100644 --- a/app/services/boards/issues/create_service.rb +++ b/app/services/boards/issues/create_service.rb @@ -35,3 +35,5 @@ module Boards end end end + +Boards::Issues::CreateService.prepend_if_ee('EE::Boards::Issues::CreateService') diff --git a/app/services/boards/issues/list_service.rb b/app/services/boards/issues/list_service.rb index 0b69661bbd0..10eb1141f59 100644 --- a/app/services/boards/issues/list_service.rb +++ b/app/services/boards/issues/list_service.rb @@ -110,3 +110,5 @@ module Boards end end end + +Boards::Issues::ListService.prepend_if_ee('EE::Boards::Issues::ListService') diff --git a/app/services/boards/issues/move_service.rb b/app/services/boards/issues/move_service.rb index 00ce27db7c8..9e3c84d03ec 100644 --- a/app/services/boards/issues/move_service.rb +++ b/app/services/boards/issues/move_service.rb @@ -137,3 +137,5 @@ module Boards end end end + +Boards::Issues::MoveService.prepend_if_ee('EE::Boards::Issues::MoveService') diff --git a/app/services/boards/list_service.rb b/app/services/boards/list_service.rb index edd1cc7c2e1..44d5a21b15f 100644 --- a/app/services/boards/list_service.rb +++ b/app/services/boards/list_service.rb @@ -18,3 +18,5 @@ module Boards end end end + +Boards::ListService.prepend_if_ee('EE::Boards::ListService') diff --git a/app/services/boards/lists/create_service.rb b/app/services/boards/lists/create_service.rb index 48d2d5abaec..eb417ac4f5f 100644 --- a/app/services/boards/lists/create_service.rb +++ b/app/services/boards/lists/create_service.rb @@ -48,3 +48,5 @@ module Boards end end end + +Boards::Lists::CreateService.prepend_if_ee('EE::Boards::Lists::CreateService') diff --git a/app/services/boards/lists/list_service.rb b/app/services/boards/lists/list_service.rb index 1f20ec8df9e..3609d9c6283 100644 --- a/app/services/boards/lists/list_service.rb +++ b/app/services/boards/lists/list_service.rb @@ -11,3 +11,5 @@ module Boards end end end + +Boards::Lists::ListService.prepend_if_ee('EE::Boards::Lists::ListService') diff --git a/app/services/boards/update_service.rb b/app/services/boards/update_service.rb index 88aced01ccd..0340836fd78 100644 --- a/app/services/boards/update_service.rb +++ b/app/services/boards/update_service.rb @@ -7,3 +7,5 @@ module Boards end end end + +Boards::UpdateService.prepend_if_ee('EE::Boards::UpdateService') diff --git a/app/services/ci/create_pipeline_service.rb b/app/services/ci/create_pipeline_service.rb index d34cafce563..539576147f3 100644 --- a/app/services/ci/create_pipeline_service.rb +++ b/app/services/ci/create_pipeline_service.rb @@ -133,3 +133,5 @@ module Ci end end end + +Ci::CreatePipelineService.prepend_if_ee('EE::Ci::CreatePipelineService') diff --git a/app/services/ci/expire_pipeline_cache_service.rb b/app/services/ci/expire_pipeline_cache_service.rb index d8d38128af6..32abd1a7626 100644 --- a/app/services/ci/expire_pipeline_cache_service.rb +++ b/app/services/ci/expire_pipeline_cache_service.rb @@ -60,3 +60,5 @@ module Ci end end end + +Ci::ExpirePipelineCacheService.prepend_if_ee('EE::Ci::ExpirePipelineCacheService') diff --git a/app/services/ci/pipeline_trigger_service.rb b/app/services/ci/pipeline_trigger_service.rb index 2dbb7c3917d..0e99f142492 100644 --- a/app/services/ci/pipeline_trigger_service.rb +++ b/app/services/ci/pipeline_trigger_service.rb @@ -52,3 +52,5 @@ module Ci end end end + +Ci::PipelineTriggerService.prepend_if_ee('EE::Ci::PipelineTriggerService') diff --git a/app/services/ci/process_build_service.rb b/app/services/ci/process_build_service.rb index d9f8e7cb452..eb92c7d1a27 100644 --- a/app/services/ci/process_build_service.rb +++ b/app/services/ci/process_build_service.rb @@ -43,3 +43,5 @@ module Ci end end end + +Ci::ProcessBuildService.prepend_if_ee('EE::Ci::ProcessBuildService') diff --git a/app/services/ci/register_job_service.rb b/app/services/ci/register_job_service.rb index 21055ad6617..d8f32ff88ce 100644 --- a/app/services/ci/register_job_service.rb +++ b/app/services/ci/register_job_service.rb @@ -182,3 +182,5 @@ module Ci end end end + +Ci::RegisterJobService.prepend_if_ee('EE::Ci::RegisterJobService') diff --git a/app/services/clusters/create_service.rb b/app/services/clusters/create_service.rb index bbbeb4b30e4..5c26c611e00 100644 --- a/app/services/clusters/create_service.rb +++ b/app/services/clusters/create_service.rb @@ -59,3 +59,5 @@ module Clusters end end end + +Clusters::CreateService.prepend_if_ee('EE::Clusters::CreateService') diff --git a/app/services/commits/create_service.rb b/app/services/commits/create_service.rb index f3be68f9602..b5401a8ea37 100644 --- a/app/services/commits/create_service.rb +++ b/app/services/commits/create_service.rb @@ -100,3 +100,5 @@ module Commits end end end + +Commits::CreateService.prepend_if_ee('EE::Commits::CreateService') diff --git a/app/services/deploy_keys/create_service.rb b/app/services/deploy_keys/create_service.rb index 0c935285657..2dac94c7ade 100644 --- a/app/services/deploy_keys/create_service.rb +++ b/app/services/deploy_keys/create_service.rb @@ -7,3 +7,5 @@ module DeployKeys end end end + +DeployKeys::CreateService.prepend_if_ee('::EE::DeployKeys::CreateService') diff --git a/app/services/emails/create_service.rb b/app/services/emails/create_service.rb index dc06a5caa40..473256d9c6f 100644 --- a/app/services/emails/create_service.rb +++ b/app/services/emails/create_service.rb @@ -11,3 +11,5 @@ module Emails end end end + +Emails::CreateService.prepend_if_ee('EE::Emails::CreateService') diff --git a/app/services/emails/destroy_service.rb b/app/services/emails/destroy_service.rb index 9ca1a03e172..a0b43ad3d08 100644 --- a/app/services/emails/destroy_service.rb +++ b/app/services/emails/destroy_service.rb @@ -17,3 +17,5 @@ module Emails end end end + +Emails::DestroyService.prepend_if_ee('EE::Emails::DestroyService') diff --git a/app/services/event_create_service.rb b/app/services/event_create_service.rb index 39266a6c961..395c5fe09ac 100644 --- a/app/services/event_create_service.rb +++ b/app/services/event_create_service.rb @@ -115,3 +115,5 @@ class EventCreateService Event.create!(attributes) end end + +EventCreateService.prepend_if_ee('EE::EventCreateService') diff --git a/app/services/git/branch_hooks_service.rb b/app/services/git/branch_hooks_service.rb index d2b037a680c..9f9d12d6cf8 100644 --- a/app/services/git/branch_hooks_service.rb +++ b/app/services/git/branch_hooks_service.rb @@ -165,3 +165,5 @@ module Git end end end + +Git::BranchHooksService.prepend_if_ee('::EE::Git::BranchHooksService') diff --git a/app/services/git/branch_push_service.rb b/app/services/git/branch_push_service.rb index c4910180787..49c54e42b7c 100644 --- a/app/services/git/branch_push_service.rb +++ b/app/services/git/branch_push_service.rb @@ -90,3 +90,5 @@ module Git end end end + +Git::BranchPushService.prepend_if_ee('::EE::Git::BranchPushService') diff --git a/app/services/git/tag_hooks_service.rb b/app/services/git/tag_hooks_service.rb index 18eb780579f..e5b109c79d6 100644 --- a/app/services/git/tag_hooks_service.rb +++ b/app/services/git/tag_hooks_service.rb @@ -34,3 +34,5 @@ module Git end end end + +Git::TagHooksService.prepend_if_ee('::EE::Git::TagHooksService') diff --git a/app/services/git/wiki_push_service.rb b/app/services/git/wiki_push_service.rb index a053f133016..d4267d4a3c5 100644 --- a/app/services/git/wiki_push_service.rb +++ b/app/services/git/wiki_push_service.rb @@ -7,3 +7,5 @@ module Git end end end + +Git::WikiPushService.prepend_if_ee('EE::Git::WikiPushService') diff --git a/app/services/groups/create_service.rb b/app/services/groups/create_service.rb index 1dd22d7a3ae..61bd50616b8 100644 --- a/app/services/groups/create_service.rb +++ b/app/services/groups/create_service.rb @@ -70,3 +70,5 @@ module Groups end end end + +Groups::CreateService.prepend_if_ee('EE::Groups::CreateService') diff --git a/app/services/groups/destroy_service.rb b/app/services/groups/destroy_service.rb index 9e00cbbbc55..c9c6b54a791 100644 --- a/app/services/groups/destroy_service.rb +++ b/app/services/groups/destroy_service.rb @@ -34,3 +34,5 @@ module Groups # rubocop: enable CodeReuse/ActiveRecord end end + +Groups::DestroyService.prepend_if_ee('EE::Groups::DestroyService') diff --git a/app/services/groups/update_service.rb b/app/services/groups/update_service.rb index 116756bacfe..534de601e20 100644 --- a/app/services/groups/update_service.rb +++ b/app/services/groups/update_service.rb @@ -66,3 +66,5 @@ module Groups end end end + +Groups::UpdateService.prepend_if_ee('EE::Groups::UpdateService') diff --git a/app/services/import/github_service.rb b/app/services/import/github_service.rb index a322a306ba4..3c57fada677 100644 --- a/app/services/import/github_service.rb +++ b/app/services/import/github_service.rb @@ -46,3 +46,5 @@ module Import end end end + +Import::GithubService.prepend_if_ee('EE::Import::GithubService') diff --git a/app/services/issuable/clone/base_service.rb b/app/services/issuable/clone/base_service.rb index 42dd9c666f5..54576e82030 100644 --- a/app/services/issuable/clone/base_service.rb +++ b/app/services/issuable/clone/base_service.rb @@ -58,3 +58,5 @@ module Issuable end end end + +Issuable::Clone::BaseService.prepend_if_ee('EE::Issuable::Clone::BaseService') diff --git a/app/services/issuable/common_system_notes_service.rb b/app/services/issuable/common_system_notes_service.rb index 77f38f8882e..6329ba81e48 100644 --- a/app/services/issuable/common_system_notes_service.rb +++ b/app/services/issuable/common_system_notes_service.rb @@ -103,3 +103,5 @@ module Issuable end end end + +Issuable::CommonSystemNotesService.prepend_if_ee('EE::Issuable::CommonSystemNotesService') diff --git a/app/services/issuable_base_service.rb b/app/services/issuable_base_service.rb index 900e5063621..3e17d75c02c 100644 --- a/app/services/issuable_base_service.rb +++ b/app/services/issuable_base_service.rb @@ -414,3 +414,5 @@ class IssuableBaseService < BaseService issuable.changes.keys != ["relative_position"] end end + +IssuableBaseService.prepend_if_ee('EE::IssuableBaseService') diff --git a/app/services/issues/build_service.rb b/app/services/issues/build_service.rb index 61615ac2058..daef468987e 100644 --- a/app/services/issues/build_service.rb +++ b/app/services/issues/build_service.rb @@ -77,3 +77,5 @@ module Issues end end end + +Issues::BuildService.prepend_if_ee('EE::Issues::BuildService') diff --git a/app/services/issues/create_service.rb b/app/services/issues/create_service.rb index 5793a15e1bc..8d1df0d87a7 100644 --- a/app/services/issues/create_service.rb +++ b/app/services/issues/create_service.rb @@ -49,3 +49,5 @@ module Issues end end end + +Issues::CreateService.prepend_if_ee('EE::Issues::CreateService') diff --git a/app/services/issues/duplicate_service.rb b/app/services/issues/duplicate_service.rb index 9b22f5e7914..82c226f601e 100644 --- a/app/services/issues/duplicate_service.rb +++ b/app/services/issues/duplicate_service.rb @@ -11,6 +11,7 @@ module Issues create_issue_canonical_note(canonical_issue, duplicate_issue) close_service.new(project, current_user, {}).execute(duplicate_issue) + duplicate_issue.update(duplicated_to: canonical_issue) end private diff --git a/app/services/issues/move_service.rb b/app/services/issues/move_service.rb index 334fadadb6f..2409396c1ac 100644 --- a/app/services/issues/move_service.rb +++ b/app/services/issues/move_service.rb @@ -64,3 +64,5 @@ module Issues end end end + +Issues::MoveService.prepend_if_ee('EE::Issues::MoveService') diff --git a/app/services/issues/update_service.rb b/app/services/issues/update_service.rb index c8f4412c9f2..dc3c363f650 100644 --- a/app/services/issues/update_service.rb +++ b/app/services/issues/update_service.rb @@ -148,3 +148,5 @@ module Issues end end end + +Issues::UpdateService.prepend_if_ee('EE::Issues::UpdateService') diff --git a/app/services/keys/create_service.rb b/app/services/keys/create_service.rb index d9fa69a88d7..32c4ab645df 100644 --- a/app/services/keys/create_service.rb +++ b/app/services/keys/create_service.rb @@ -9,3 +9,5 @@ module Keys end end end + +Keys::CreateService.prepend_if_ee('EE::Keys::CreateService') diff --git a/app/services/keys/destroy_service.rb b/app/services/keys/destroy_service.rb index 159455f80f3..4552c5cf9a2 100644 --- a/app/services/keys/destroy_service.rb +++ b/app/services/keys/destroy_service.rb @@ -12,3 +12,5 @@ module Keys end end end + +Keys::DestroyService.prepend_if_ee('EE::Keys::DestroyService') diff --git a/app/services/lfs/lock_file_service.rb b/app/services/lfs/lock_file_service.rb index c7730d24bdc..383a0d6b4e3 100644 --- a/app/services/lfs/lock_file_service.rb +++ b/app/services/lfs/lock_file_service.rb @@ -41,3 +41,5 @@ module Lfs end end end + +Lfs::LockFileService.prepend_if_ee('EE::Lfs::LockFileService') diff --git a/app/services/lfs/unlock_file_service.rb b/app/services/lfs/unlock_file_service.rb index a42916d86bb..ea5a67b727f 100644 --- a/app/services/lfs/unlock_file_service.rb +++ b/app/services/lfs/unlock_file_service.rb @@ -45,3 +45,5 @@ module Lfs # rubocop: enable CodeReuse/ActiveRecord end end + +Lfs::UnlockFileService.prepend_if_ee('EE::Lfs::UnlockFileService') diff --git a/app/services/members/approve_access_request_service.rb b/app/services/members/approve_access_request_service.rb index 52b890d1821..e79c5f69a30 100644 --- a/app/services/members/approve_access_request_service.rb +++ b/app/services/members/approve_access_request_service.rb @@ -20,3 +20,5 @@ module Members end end end + +Members::ApproveAccessRequestService.prepend_if_ee('EE::Members::ApproveAccessRequestService') diff --git a/app/services/members/create_service.rb b/app/services/members/create_service.rb index d6b17ec10be..0b729981a93 100644 --- a/app/services/members/create_service.rb +++ b/app/services/members/create_service.rb @@ -52,3 +52,5 @@ module Members end end end + +Members::CreateService.prepend_if_ee('EE::Members::CreateService') diff --git a/app/services/members/destroy_service.rb b/app/services/members/destroy_service.rb index 0164760920f..20f64a99ad7 100644 --- a/app/services/members/destroy_service.rb +++ b/app/services/members/destroy_service.rb @@ -66,3 +66,5 @@ module Members end end end + +Members::DestroyService.prepend_if_ee('EE::Members::DestroyService') diff --git a/app/services/members/update_service.rb b/app/services/members/update_service.rb index ff8d5c1d8c9..fdd2c62a452 100644 --- a/app/services/members/update_service.rb +++ b/app/services/members/update_service.rb @@ -25,3 +25,5 @@ module Members end end end + +Members::UpdateService.prepend_if_ee('EE::Members::UpdateService') diff --git a/app/services/merge_request_metrics_service.rb b/app/services/merge_request_metrics_service.rb index 4e88b77c855..9ea71838011 100644 --- a/app/services/merge_request_metrics_service.rb +++ b/app/services/merge_request_metrics_service.rb @@ -19,3 +19,5 @@ class MergeRequestMetricsService update!(latest_closed_by_id: nil, latest_closed_at: nil) end end + +MergeRequestMetricsService.prepend_if_ee('EE::MergeRequestMetricsService') diff --git a/app/services/merge_requests/base_service.rb b/app/services/merge_requests/base_service.rb index c6aae4c28f2..7d4227e4a41 100644 --- a/app/services/merge_requests/base_service.rb +++ b/app/services/merge_requests/base_service.rb @@ -90,3 +90,5 @@ module MergeRequests end end end + +MergeRequests::BaseService.prepend_if_ee('EE::MergeRequests::BaseService') diff --git a/app/services/merge_requests/build_service.rb b/app/services/merge_requests/build_service.rb index 88ed0c3ef4c..9cd6f3959fd 100644 --- a/app/services/merge_requests/build_service.rb +++ b/app/services/merge_requests/build_service.rb @@ -264,3 +264,5 @@ module MergeRequests end end end + +MergeRequests::BuildService.prepend_if_ee('EE::MergeRequests::BuildService') diff --git a/app/services/merge_requests/create_pipeline_service.rb b/app/services/merge_requests/create_pipeline_service.rb index 03246cc1920..9eb11820f7a 100644 --- a/app/services/merge_requests/create_pipeline_service.rb +++ b/app/services/merge_requests/create_pipeline_service.rb @@ -35,3 +35,5 @@ module MergeRequests end end end + +MergeRequests::CreatePipelineService.prepend_if_ee('EE::MergeRequests::CreatePipelineService') diff --git a/app/services/merge_requests/create_service.rb b/app/services/merge_requests/create_service.rb index a69678a4422..1c730232abb 100644 --- a/app/services/merge_requests/create_service.rb +++ b/app/services/merge_requests/create_service.rb @@ -67,3 +67,5 @@ module MergeRequests end end end + +MergeRequests::CreateService.include_if_ee('EE::MergeRequests::CreateService') diff --git a/app/services/merge_requests/merge_base_service.rb b/app/services/merge_requests/merge_base_service.rb index 1ed396cee1e..3f7f8bcdcbf 100644 --- a/app/services/merge_requests/merge_base_service.rb +++ b/app/services/merge_requests/merge_base_service.rb @@ -72,3 +72,5 @@ module MergeRequests end end end + +MergeRequests::MergeBaseService.prepend_if_ee('EE::MergeRequests::MergeBaseService') diff --git a/app/services/merge_requests/post_merge_service.rb b/app/services/merge_requests/post_merge_service.rb index c13f7dd5088..fbe6c48ac28 100644 --- a/app/services/merge_requests/post_merge_service.rb +++ b/app/services/merge_requests/post_merge_service.rb @@ -53,3 +53,5 @@ module MergeRequests end end end + +MergeRequests::PostMergeService.prepend_if_ee('EE::MergeRequests::PostMergeService') diff --git a/app/services/merge_requests/refresh_service.rb b/app/services/merge_requests/refresh_service.rb index 8961d2e1023..f54642d7bd9 100644 --- a/app/services/merge_requests/refresh_service.rb +++ b/app/services/merge_requests/refresh_service.rb @@ -257,3 +257,5 @@ module MergeRequests end end end + +MergeRequests::RefreshService.prepend_if_ee('EE::MergeRequests::RefreshService') diff --git a/app/services/merge_requests/update_service.rb b/app/services/merge_requests/update_service.rb index d361e96babf..4acc3f1981a 100644 --- a/app/services/merge_requests/update_service.rb +++ b/app/services/merge_requests/update_service.rb @@ -130,3 +130,5 @@ module MergeRequests end end end + +MergeRequests::UpdateService.prepend_if_ee('EE::MergeRequests::UpdateService') diff --git a/app/services/milestones/promote_service.rb b/app/services/milestones/promote_service.rb index 0fe67067eb5..80e6456f729 100644 --- a/app/services/milestones/promote_service.rb +++ b/app/services/milestones/promote_service.rb @@ -89,3 +89,5 @@ module Milestones end end end + +Milestones::PromoteService.prepend_if_ee('EE::Milestones::PromoteService') diff --git a/app/services/milestones/update_service.rb b/app/services/milestones/update_service.rb index 01ab8b37bac..c445c816554 100644 --- a/app/services/milestones/update_service.rb +++ b/app/services/milestones/update_service.rb @@ -22,3 +22,5 @@ module Milestones # rubocop: enable CodeReuse/ActiveRecord end end + +Milestones::UpdateService.prepend_if_ee('EE::Milestones::UpdateService') diff --git a/app/services/notes/quick_actions_service.rb b/app/services/notes/quick_actions_service.rb index 0852a708240..076df10bf6f 100644 --- a/app/services/notes/quick_actions_service.rb +++ b/app/services/notes/quick_actions_service.rb @@ -54,3 +54,5 @@ module Notes end end end + +Notes::QuickActionsService.prepend_if_ee('EE::Notes::QuickActionsService') diff --git a/app/services/notification_recipient_service.rb b/app/services/notification_recipient_service.rb index ca3f0b73096..fca64270cae 100644 --- a/app/services/notification_recipient_service.rb +++ b/app/services/notification_recipient_service.rb @@ -400,3 +400,6 @@ module NotificationRecipientService end end end + +NotificationRecipientService::Builder::Default.prepend_if_ee('EE::NotificationRecipientBuilders::Default') # rubocop: disable Cop/InjectEnterpriseEditionModule +NotificationRecipientService.prepend_if_ee('EE::NotificationRecipientService') diff --git a/app/services/notification_service.rb b/app/services/notification_service.rb index a4243b7bc5e..ed357aa0392 100644 --- a/app/services/notification_service.rb +++ b/app/services/notification_service.rb @@ -622,3 +622,5 @@ class NotificationService source.respond_to?(:group) && source.group end end + +NotificationService.prepend_if_ee('EE::NotificationService') diff --git a/app/services/projects/after_rename_service.rb b/app/services/projects/after_rename_service.rb index fafdecb3222..2a35a07d555 100644 --- a/app/services/projects/after_rename_service.rb +++ b/app/services/projects/after_rename_service.rb @@ -139,3 +139,5 @@ module Projects end end end + +Projects::AfterRenameService.prepend_if_ee('EE::Projects::AfterRenameService') diff --git a/app/services/projects/autocomplete_service.rb b/app/services/projects/autocomplete_service.rb index 3dad90188cf..53bd954eab6 100644 --- a/app/services/projects/autocomplete_service.rb +++ b/app/services/projects/autocomplete_service.rb @@ -38,3 +38,5 @@ module Projects end end end + +Projects::AutocompleteService.prepend_if_ee('EE::Projects::AutocompleteService') diff --git a/app/services/projects/cleanup_service.rb b/app/services/projects/cleanup_service.rb index 5972bfd4071..9b4114ff42f 100644 --- a/app/services/projects/cleanup_service.rb +++ b/app/services/projects/cleanup_service.rb @@ -89,3 +89,5 @@ module Projects end end end + +Projects::CleanupService.prepend_if_ee('EE::Projects::CleanupService') diff --git a/app/services/projects/create_from_template_service.rb b/app/services/projects/create_from_template_service.rb index 678bc0d24c3..31977a7c76a 100644 --- a/app/services/projects/create_from_template_service.rb +++ b/app/services/projects/create_from_template_service.rb @@ -26,3 +26,5 @@ module Projects end end end + +Projects::CreateFromTemplateService.prepend_if_ee('EE::Projects::CreateFromTemplateService') diff --git a/app/services/projects/create_service.rb b/app/services/projects/create_service.rb index 942a45286b2..728eb039b54 100644 --- a/app/services/projects/create_service.rb +++ b/app/services/projects/create_service.rb @@ -199,3 +199,5 @@ module Projects end end end + +Projects::CreateService.prepend_if_ee('EE::Projects::CreateService') diff --git a/app/services/projects/destroy_service.rb b/app/services/projects/destroy_service.rb index 108c4a79cde..5fdf98c3c5e 100644 --- a/app/services/projects/destroy_service.rb +++ b/app/services/projects/destroy_service.rb @@ -228,3 +228,5 @@ module Projects end end end + +Projects::DestroyService.prepend_if_ee('EE::Projects::DestroyService') diff --git a/app/services/projects/disable_deploy_key_service.rb b/app/services/projects/disable_deploy_key_service.rb index e483c0708c4..9fb2e3398b2 100644 --- a/app/services/projects/disable_deploy_key_service.rb +++ b/app/services/projects/disable_deploy_key_service.rb @@ -11,3 +11,5 @@ module Projects end end end + +Projects::DisableDeployKeyService.prepend_if_ee('EE::Projects::DisableDeployKeyService') diff --git a/app/services/projects/enable_deploy_key_service.rb b/app/services/projects/enable_deploy_key_service.rb index 38219cacee9..0a24137bd61 100644 --- a/app/services/projects/enable_deploy_key_service.rb +++ b/app/services/projects/enable_deploy_key_service.rb @@ -26,3 +26,5 @@ module Projects end end end + +Projects::EnableDeployKeyService.prepend_if_ee('EE::Projects::EnableDeployKeyService') diff --git a/app/services/projects/gitlab_projects_import_service.rb b/app/services/projects/gitlab_projects_import_service.rb index a315adf42f0..234ebbc6651 100644 --- a/app/services/projects/gitlab_projects_import_service.rb +++ b/app/services/projects/gitlab_projects_import_service.rb @@ -69,3 +69,5 @@ module Projects end end end + +Projects::GitlabProjectsImportService.prepend_if_ee('EE::Projects::GitlabProjectsImportService') diff --git a/app/services/projects/group_links/create_service.rb b/app/services/projects/group_links/create_service.rb index e3d5bea0852..241948b335b 100644 --- a/app/services/projects/group_links/create_service.rb +++ b/app/services/projects/group_links/create_service.rb @@ -21,3 +21,5 @@ module Projects end end end + +Projects::GroupLinks::CreateService.prepend_if_ee('EE::Projects::GroupLinks::CreateService') diff --git a/app/services/projects/group_links/destroy_service.rb b/app/services/projects/group_links/destroy_service.rb index 8aefad048ce..c96dcaae8d5 100644 --- a/app/services/projects/group_links/destroy_service.rb +++ b/app/services/projects/group_links/destroy_service.rb @@ -11,3 +11,5 @@ module Projects end end end + +Projects::GroupLinks::DestroyService.prepend_if_ee('EE::Projects::GroupLinks::DestroyService') diff --git a/app/services/projects/hashed_storage/migrate_attachments_service.rb b/app/services/projects/hashed_storage/migrate_attachments_service.rb index affe6e5668d..0cbff283102 100644 --- a/app/services/projects/hashed_storage/migrate_attachments_service.rb +++ b/app/services/projects/hashed_storage/migrate_attachments_service.rb @@ -37,3 +37,5 @@ module Projects end end end + +Projects::HashedStorage::MigrateAttachmentsService.prepend_if_ee('EE::Projects::HashedStorage::MigrateAttachmentsService') diff --git a/app/services/projects/hashed_storage/migrate_repository_service.rb b/app/services/projects/hashed_storage/migrate_repository_service.rb index e8393128d58..e248a13c702 100644 --- a/app/services/projects/hashed_storage/migrate_repository_service.rb +++ b/app/services/projects/hashed_storage/migrate_repository_service.rb @@ -38,3 +38,5 @@ module Projects end end end + +Projects::HashedStorage::MigrateRepositoryService.prepend_if_ee('EE::Projects::HashedStorage::MigrateRepositoryService') diff --git a/app/services/projects/operations/update_service.rb b/app/services/projects/operations/update_service.rb index 48eddb0e8d0..dd72c2844c2 100644 --- a/app/services/projects/operations/update_service.rb +++ b/app/services/projects/operations/update_service.rb @@ -47,3 +47,5 @@ module Projects end end end + +Projects::Operations::UpdateService.prepend_if_ee('::EE::Projects::Operations::UpdateService') diff --git a/app/services/projects/transfer_service.rb b/app/services/projects/transfer_service.rb index 078a751025f..4b3aca58dd7 100644 --- a/app/services/projects/transfer_service.rb +++ b/app/services/projects/transfer_service.rb @@ -168,3 +168,5 @@ module Projects end end end + +Projects::TransferService.prepend_if_ee('EE::Projects::TransferService') diff --git a/app/services/projects/update_service.rb b/app/services/projects/update_service.rb index 8acbdc7e02b..51a6f62e597 100644 --- a/app/services/projects/update_service.rb +++ b/app/services/projects/update_service.rb @@ -139,3 +139,5 @@ module Projects end end end + +Projects::UpdateService.prepend_if_ee('EE::Projects::UpdateService') diff --git a/app/services/protected_branches/access_level_params.rb b/app/services/protected_branches/access_level_params.rb index a7ef573ff0b..e34bc23b4dc 100644 --- a/app/services/protected_branches/access_level_params.rb +++ b/app/services/protected_branches/access_level_params.rb @@ -33,3 +33,5 @@ module ProtectedBranches end end end + +ProtectedBranches::AccessLevelParams.prepend_if_ee('EE::ProtectedBranches::AccessLevelParams') diff --git a/app/services/protected_branches/api_service.rb b/app/services/protected_branches/api_service.rb index 1b13dace5f2..ac4917d6590 100644 --- a/app/services/protected_branches/api_service.rb +++ b/app/services/protected_branches/api_service.rb @@ -15,3 +15,5 @@ module ProtectedBranches end end end + +ProtectedBranches::ApiService.prepend_if_ee('EE::ProtectedBranches::ApiService') diff --git a/app/services/protected_branches/create_service.rb b/app/services/protected_branches/create_service.rb index 6b2836bba39..3c86d7d087d 100644 --- a/app/services/protected_branches/create_service.rb +++ b/app/services/protected_branches/create_service.rb @@ -25,3 +25,5 @@ module ProtectedBranches end end end + +ProtectedBranches::CreateService.prepend_if_ee('EE::ProtectedBranches::CreateService') diff --git a/app/services/protected_branches/legacy_api_update_service.rb b/app/services/protected_branches/legacy_api_update_service.rb index 7cb8d41818f..65dc3297ae8 100644 --- a/app/services/protected_branches/legacy_api_update_service.rb +++ b/app/services/protected_branches/legacy_api_update_service.rb @@ -48,3 +48,5 @@ module ProtectedBranches end end end + +ProtectedBranches::LegacyApiUpdateService.prepend_if_ee('EE::ProtectedBranches::LegacyApiUpdateService') diff --git a/app/services/quick_actions/interpret_service.rb b/app/services/quick_actions/interpret_service.rb index e0924608a6d..a14e0515a1f 100644 --- a/app/services/quick_actions/interpret_service.rb +++ b/app/services/quick_actions/interpret_service.rb @@ -177,3 +177,5 @@ module QuickActions # rubocop: enable CodeReuse/ActiveRecord end end + +QuickActions::InterpretService.prepend_if_ee('EE::QuickActions::InterpretService') diff --git a/app/services/resource_events/change_labels_service.rb b/app/services/resource_events/change_labels_service.rb index b45e567079b..e0d019f54be 100644 --- a/app/services/resource_events/change_labels_service.rb +++ b/app/services/resource_events/change_labels_service.rb @@ -40,3 +40,5 @@ module ResourceEvents end end end + +ResourceEvents::ChangeLabelsService.prepend_if_ee('EE::ResourceEvents::ChangeLabelsService') diff --git a/app/services/search/global_service.rb b/app/services/search/global_service.rb index 18a90c952fa..c841cbfaa00 100644 --- a/app/services/search/global_service.rb +++ b/app/services/search/global_service.rb @@ -35,3 +35,5 @@ module Search end end end + +Search::GlobalService.prepend_if_ee('EE::Search::GlobalService') diff --git a/app/services/search/group_service.rb b/app/services/search/group_service.rb index 6f3b5f00b86..4dbd9eb14bb 100644 --- a/app/services/search/group_service.rb +++ b/app/services/search/group_service.rb @@ -25,3 +25,5 @@ module Search end end end + +Search::GroupService.prepend_if_ee('EE::Search::GroupService') diff --git a/app/services/search/project_service.rb b/app/services/search/project_service.rb index 32d5cd7ddb2..17a322c2665 100644 --- a/app/services/search/project_service.rb +++ b/app/services/search/project_service.rb @@ -25,3 +25,5 @@ module Search end end end + +Search::ProjectService.prepend_if_ee('EE::Search::ProjectService') diff --git a/app/services/search/snippet_service.rb b/app/services/search/snippet_service.rb index e899a36f468..7c6c6878400 100644 --- a/app/services/search/snippet_service.rb +++ b/app/services/search/snippet_service.rb @@ -19,3 +19,5 @@ module Search end end end + +Search::SnippetService.prepend_if_ee('::EE::Search::SnippetService') diff --git a/app/services/search_service.rb b/app/services/search_service.rb index e0cbfac2420..91c0f9ba104 100644 --- a/app/services/search_service.rb +++ b/app/services/search_service.rb @@ -69,3 +69,5 @@ class SearchService attr_reader :current_user, :params end + +SearchService.prepend_if_ee('EE::SearchService') diff --git a/app/services/system_hooks_service.rb b/app/services/system_hooks_service.rb index 34260d12a62..06d2037fb63 100644 --- a/app/services/system_hooks_service.rb +++ b/app/services/system_hooks_service.rb @@ -150,3 +150,5 @@ class SystemHooksService } end end + +SystemHooksService.prepend_if_ee('EE::SystemHooksService') diff --git a/app/services/system_note_service.rb b/app/services/system_note_service.rb index 1b48b20e28b..ad8acb26a2d 100644 --- a/app/services/system_note_service.rb +++ b/app/services/system_note_service.rb @@ -706,3 +706,5 @@ module SystemNoteService ActionController::Base.helpers.content_tag(*args) end end + +SystemNoteService.prepend_if_ee('EE::SystemNoteService') diff --git a/app/services/todo_service.rb b/app/services/todo_service.rb index b1256df35d6..b1b0fb641df 100644 --- a/app/services/todo_service.rb +++ b/app/services/todo_service.rb @@ -333,3 +333,5 @@ class TodoService PendingTodosFinder.new(user, criteria).execute end end + +TodoService.prepend_if_ee('EE::TodoService') diff --git a/app/services/update_deployment_service.rb b/app/services/update_deployment_service.rb index dcafebae52d..730210c611a 100644 --- a/app/services/update_deployment_service.rb +++ b/app/services/update_deployment_service.rb @@ -53,3 +53,5 @@ class UpdateDeploymentService environment_options[:action] || 'start' end end + +UpdateDeploymentService.prepend_if_ee('EE::UpdateDeploymentService') diff --git a/app/services/user_project_access_changed_service.rb b/app/services/user_project_access_changed_service.rb index adca43660e8..21b52944800 100644 --- a/app/services/user_project_access_changed_service.rb +++ b/app/services/user_project_access_changed_service.rb @@ -15,3 +15,5 @@ class UserProjectAccessChangedService end end end + +UserProjectAccessChangedService.prepend_if_ee('EE::UserProjectAccessChangedService') diff --git a/app/services/users/build_service.rb b/app/services/users/build_service.rb index 026bcfcdaf4..8c85ad9ffd8 100644 --- a/app/services/users/build_service.rb +++ b/app/services/users/build_service.rb @@ -125,3 +125,5 @@ module Users end end end + +Users::BuildService.prepend_if_ee('EE::Users::BuildService') diff --git a/app/services/users/destroy_service.rb b/app/services/users/destroy_service.rb index 73fa6089945..e341c7f0537 100644 --- a/app/services/users/destroy_service.rb +++ b/app/services/users/destroy_service.rb @@ -64,3 +64,5 @@ module Users end end end + +Users::DestroyService.prepend_if_ee('EE::Users::DestroyService') diff --git a/app/services/users/migrate_to_ghost_user_service.rb b/app/services/users/migrate_to_ghost_user_service.rb index a66b6627e40..e7186fdfb63 100644 --- a/app/services/users/migrate_to_ghost_user_service.rb +++ b/app/services/users/migrate_to_ghost_user_service.rb @@ -81,3 +81,5 @@ module Users end end end + +Users::MigrateToGhostUserService.prepend_if_ee('EE::Users::MigrateToGhostUserService') diff --git a/app/services/users/update_service.rb b/app/services/users/update_service.rb index 8f52e9cb23f..eea5ff6e5db 100644 --- a/app/services/users/update_service.rb +++ b/app/services/users/update_service.rb @@ -80,3 +80,5 @@ module Users end end end + +Users::UpdateService.prepend_if_ee('EE::Users::UpdateService') diff --git a/app/services/wiki_pages/base_service.rb b/app/services/wiki_pages/base_service.rb index b9df690c2b7..82c15ffc9b9 100644 --- a/app/services/wiki_pages/base_service.rb +++ b/app/services/wiki_pages/base_service.rb @@ -17,3 +17,5 @@ module WikiPages end end end + +WikiPages::BaseService.prepend_if_ee('EE::WikiPages::BaseService') |