Skip to content
Snippets Groups Projects
Commit 8cb5ce6d authored by Brett Walker's avatar Brett Walker
Browse files

Convert GraphQL::STRING_TYPE to GraphQL::Types::String

When using the new graphql interpreter, we need to be using the updated
types, otherwise validation fails.  They are the same types, so external
interfaces won't change.
parent 98f7ef7f
No related branches found
No related tags found
No related merge requests found
Showing
with 30 additions and 30 deletions
......@@ -10,13 +10,13 @@ class DeleteJobs < BaseMutation
Gitlab::ApplicationContext::KNOWN_KEYS.each do |key|
argument key,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
required: false,
description: "Delete jobs matching #{key} in the context metadata"
end
argument :queue_name,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
required: true,
description: 'The name of the queue to delete jobs from.'
......
......@@ -7,7 +7,7 @@ class SetAssignees < Base
graphql_name 'AlertSetAssignees'
argument :assignee_usernames,
[GraphQL::STRING_TYPE],
[GraphQL::Types::String],
required: true,
description: 'The usernames to assign to the alert. Replaces existing assignees by default.'
......
......@@ -9,7 +9,7 @@ class Base < BaseMutation
required: true,
description: "The project the alert to mutate is in."
argument :iid, GraphQL::STRING_TYPE,
argument :iid, GraphQL::Types::String,
required: true,
description: "The IID of the alert to mutate."
......
......@@ -12,7 +12,7 @@ class Create < HttpIntegrationBase
required: true,
description: 'The project to create the integration in.'
argument :name, GraphQL::STRING_TYPE,
argument :name, GraphQL::Types::String,
required: true,
description: 'The name of the integration.'
......
......@@ -10,7 +10,7 @@ class Update < HttpIntegrationBase
required: true,
description: "The ID of the integration to mutate."
argument :name, GraphQL::STRING_TYPE,
argument :name, GraphQL::Types::String,
required: false,
description: "The name of the integration."
......
......@@ -16,7 +16,7 @@ class Create < PrometheusIntegrationBase
required: true,
description: 'Whether the integration is receiving alerts.'
argument :api_url, GraphQL::STRING_TYPE,
argument :api_url, GraphQL::Types::String,
required: true,
description: 'Endpoint at which Prometheus can be queried.'
......
......@@ -14,7 +14,7 @@ class Update < PrometheusIntegrationBase
required: false,
description: "Whether the integration is receiving alerts."
argument :api_url, GraphQL::STRING_TYPE,
argument :api_url, GraphQL::Types::String,
required: false,
description: "Endpoint at which Prometheus can be queried."
......
......@@ -15,7 +15,7 @@ class Base < BaseMutation
description: 'The global ID of the awardable resource.'
argument :name,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
required: true,
description: copy_field_description(Types::AwardEmojis::AwardEmojiType, :name)
......
......@@ -11,7 +11,7 @@ class BaseMutation < GraphQL::Schema::RelayClassicMutation
field_class ::Types::BaseField
argument_class ::Types::BaseArgument
field :errors, [GraphQL::STRING_TYPE],
field :errors, [GraphQL::Types::String],
null: false,
description: 'Errors encountered during execution of the mutation.'
......
......@@ -7,7 +7,7 @@ module CommonMutationArguments
included do
argument :name,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
required: false,
description: 'The board name.'
argument :hide_backlog_list,
......
......@@ -18,7 +18,7 @@ class IssueMoveList < Mutations::Issues::Base
required: true,
description: 'Project the issue to mutate is in.'
argument :iid, GraphQL::STRING_TYPE,
argument :iid, GraphQL::Types::String,
required: true,
description: 'IID of the issue to mutate.'
......
......@@ -11,12 +11,12 @@ class Create < BaseMutation
required: true,
description: 'Project full path the branch is associated with.'
argument :name, GraphQL::STRING_TYPE,
argument :name, GraphQL::Types::String,
required: true,
description: 'Name of the branch.'
argument :ref,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
required: true,
description: 'Branch name or commit SHA to create branch from.'
......
......@@ -14,7 +14,7 @@ class Update < BaseMutation
required: true,
description: 'ID of the runner to update.'
argument :description, GraphQL::STRING_TYPE,
argument :description, GraphQL::Types::String,
required: false,
description: 'Description of the runner.'
......@@ -37,7 +37,7 @@ class Update < BaseMutation
required: false,
description: 'Indicates the runner is able to run untagged jobs.'
argument :tag_list, [GraphQL::STRING_TYPE], required: false,
argument :tag_list, [GraphQL::Types::String], required: false,
description: 'Tags associated with the runner.'
field :runner,
......
......@@ -19,7 +19,7 @@ class Reset < BaseMutation
description: 'ID of the project or group to reset the token for. Omit if resetting instance runner token.'
field :token,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
null: true,
description: 'The runner token after mutation.'
......
......@@ -16,16 +16,16 @@ class UrlHelpers
required: true,
description: 'Project full path the branch is associated with.'
argument :branch, GraphQL::STRING_TYPE,
argument :branch, GraphQL::Types::String,
required: true,
description: 'Name of the branch to commit into, it can be a new branch.'
argument :start_branch, GraphQL::STRING_TYPE,
argument :start_branch, GraphQL::Types::String,
required: false,
description: 'If on a new branch, name of the original branch.'
argument :message,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
required: true,
description: copy_field_description(Types::CommitType, :message)
......@@ -35,7 +35,7 @@ class UrlHelpers
description: 'Array of action hashes to commit as a batch.'
field :commit_pipeline_path,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
null: true,
description: "ETag path for the commit's pipeline."
......@@ -45,7 +45,7 @@ class UrlHelpers
description: 'The commit after mutation.'
field :content,
[GraphQL::STRING_TYPE],
[GraphQL::Types::String],
null: true,
description: 'Contents of the commit.'
......
......@@ -6,7 +6,7 @@ module Assignable
included do
argument :assignee_usernames,
[GraphQL::STRING_TYPE],
[GraphQL::Types::String],
required: true,
description: 'The usernames to assign to the resource. Replaces existing assignees by default.'
......
......@@ -13,7 +13,7 @@ module CanMutateSpammable
}.freeze
included do
argument :captcha_response, GraphQL::STRING_TYPE,
argument :captcha_response, GraphQL::Types::String,
required: false,
deprecated: DEPRECATION_NOTICE,
description: 'A valid CAPTCHA response value obtained by using the provided captchaSiteKey with a CAPTCHA API to present a challenge to be solved on the client. Required to resubmit if the previous operation returned "NeedsCaptchaResponse: true".'
......@@ -42,7 +42,7 @@ module CanMutateSpammable
description: 'The spam log ID which must be passed along with a valid CAPTCHA response for an operation to be completed. Included only when an operation was not completed because "NeedsCaptchaResponse" is true.'
field :captcha_site_key,
GraphQL::STRING_TYPE,
GraphQL::Types::String,
null: true,
deprecated: DEPRECATION_NOTICE,
description: 'The CAPTCHA site key which must be used to render a challenge for the user to solve to obtain a valid captchaResponse value. Included only when an operation was not completed because "NeedsCaptchaResponse" is true.'
......
......@@ -17,7 +17,7 @@ class DestroyTags < ::Mutations::ContainerRepositories::DestroyBase
description: 'ID of the container repository.'
argument :tag_names,
[GraphQL::STRING_TYPE],
[GraphQL::Types::String],
required: true,
description: "Container repository tag(s) to delete. Total number can't be greater than #{LIMIT}",
prepare: ->(tag_names, _) do
......@@ -27,7 +27,7 @@ class DestroyTags < ::Mutations::ContainerRepositories::DestroyBase
end
field :deleted_tag_names,
[GraphQL::STRING_TYPE],
[GraphQL::Types::String],
description: 'Deleted container repository tags.',
null: false
......
......@@ -18,11 +18,11 @@ class Create < BaseMutation
required: true,
description: 'Namespace full path the emoji is associated with.'
argument :name, GraphQL::STRING_TYPE,
argument :name, GraphQL::Types::String,
required: true,
description: 'Name of the emoji.'
argument :url, GraphQL::STRING_TYPE,
argument :url, GraphQL::Types::String,
required: true,
as: :file,
description: 'Location of the emoji file.'
......
......@@ -7,7 +7,7 @@ class Delete < Base
graphql_name "DesignManagementDelete"
argument :filenames, [GraphQL::STRING_TYPE],
argument :filenames, [GraphQL::Types::String],
required: true,
description: "The filenames of the designs to delete.",
prepare: ->(names, _ctx) do
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment