Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-09-20 14:18:08 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-09-20 14:18:08 +0300
commit5afcbe03ead9ada87621888a31a62652b10a7e4f (patch)
tree9918b67a0d0f0bafa6542e839a8be37adf73102d /app/graphql/mutations/metrics/dashboard/annotations/create.rb
parentc97c0201564848c1f53226fe19d71fdcc472f7d0 (diff)
Add latest changes from gitlab-org/gitlab@16-4-stable-eev16.4.0-rc42
Diffstat (limited to 'app/graphql/mutations/metrics/dashboard/annotations/create.rb')
-rw-r--r--app/graphql/mutations/metrics/dashboard/annotations/create.rb24
1 files changed, 2 insertions, 22 deletions
diff --git a/app/graphql/mutations/metrics/dashboard/annotations/create.rb b/app/graphql/mutations/metrics/dashboard/annotations/create.rb
index 59ddffe3aad..e544b96f679 100644
--- a/app/graphql/mutations/metrics/dashboard/annotations/create.rb
+++ b/app/graphql/mutations/metrics/dashboard/annotations/create.rb
@@ -70,28 +70,8 @@ module Mutations
private
- def ready?(**args)
- raise_resource_not_available_error! if Feature.enabled?(:remove_monitor_metrics)
-
- # Raise error if both cluster_id and environment_id are present or neither is present
- unless args[:cluster_id].present? ^ args[:environment_id].present?
- raise Gitlab::Graphql::Errors::ArgumentError, ANNOTATION_SOURCE_ARGUMENT_ERROR
- end
-
- super(**args)
- end
-
- def annotation_create_params(args)
- annotation_source = AnnotationSource.new(object: annotation_source(args))
-
- args[annotation_source.type] = annotation_source.object
-
- args
- end
-
- def annotation_source(args)
- annotation_source_id = args[:cluster_id] || args[:environment_id]
- authorized_find!(id: annotation_source_id)
+ def ready?(**_args)
+ raise_resource_not_available_error!
end
end
end