diff options
Diffstat (limited to 'app/graphql/mutations/custom_emoji/create.rb')
-rw-r--r-- | app/graphql/mutations/custom_emoji/create.rb | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/app/graphql/mutations/custom_emoji/create.rb b/app/graphql/mutations/custom_emoji/create.rb index 269ea6c9999..535ff44a7fd 100644 --- a/app/graphql/mutations/custom_emoji/create.rb +++ b/app/graphql/mutations/custom_emoji/create.rb @@ -28,6 +28,10 @@ module Mutations description: 'Location of the emoji file.' def resolve(group_path:, **args) + if Feature.disabled?(:custom_emoji) + raise Gitlab::Graphql::Errors::ResourceNotAvailable, 'Custom emoji feature is disabled' + end + group = authorized_find!(group_path: group_path) # See https://gitlab.com/gitlab-org/gitlab/-/merge_requests/37911#note_444682238 args[:external] = true |