diff --git a/ee/app/graphql/types/geo/registry_type.rb b/ee/app/graphql/types/geo/registry_type.rb index 9b41d5c17f41b06c2425150e7fd36b8ef9be5778..383b93d74957a7bbcdc3652b657ee559ef77b492 100644 --- a/ee/app/graphql/types/geo/registry_type.rb +++ b/ee/app/graphql/types/geo/registry_type.rb @@ -23,10 +23,8 @@ module RegistryType field :verification_checksum, GraphQL::Types::String, null: true, description: "The local checksum of the #{graphql_name}" field :verification_failure, GraphQL::Types::String, null: true, description: "Error message during verification of the #{graphql_name}" - # NOTE: remove respond_to? when GroupWikiRepositoryRegistry includes the verification state machine - # Issue: https://gitlab.com/gitlab-org/gitlab/-/issues/323897 def verification_state_name_value - object.verification_state_name.to_s.gsub('verification_', '') if object.respond_to?(:verification_state_name) + object.verification_state_name.to_s.gsub('verification_', '') end end end diff --git a/ee/spec/support/shared_examples/requests/api/graphql/geo/registries_shared_examples.rb b/ee/spec/support/shared_examples/requests/api/graphql/geo/registries_shared_examples.rb index 344a4193767b1130b57778eb0fc0dc0cece53adb..1a9bbdd877e329028b0a863b6162bcbeabd7e4f5 100644 --- a/ee/spec/support/shared_examples/requests/api/graphql/geo/registries_shared_examples.rb +++ b/ee/spec/support/shared_examples/requests/api/graphql/geo/registries_shared_examples.rb @@ -132,13 +132,7 @@ def verification_data_to_registry_hash(data, registry) data['verificationFailure'] = registry.verification_failure data['verificationRetryCount'] = registry.verification_retry_count data['verificationStartedAt'] = registry.verification_started_at - - # NOTE: remove respond_to? when GroupWikiRepositoryRegistry includes the verification state machine - # Issue: https://gitlab.com/gitlab-org/gitlab/-/issues/323897 - data['verificationState'] = if registry.respond_to?(:verification_state_name) - registry.verification_state_name.to_s.gsub('verification_', '').upcase - end - + data['verificationState'] = registry.verification_state_name.to_s.gsub('verification_', '').upcase data['verifiedAt'] = registry.verified_at if verification_enabled data['verificationRetryAt'] = registry.verification_retry_at if verification_enabled data