You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: delete.rb
    path of file: ./repos/gitlabhq/app/graphql/mutations/uploads
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

module Mutations
  module Uploads
    class Delete < BaseMutation
      graphql_name 'UploadDelete'
      description 'Deletes an upload.'

      include Mutations::Resol
    
      def resolve(args)
        parent = authorized_resource_parent_find!(args)

        result = ::Uploads::DestroyService.new(parent, current_user).execute(args[:secret], args[:filename])

        {
          upload: result[:status] == :success ? result[:upload] : nil,
          errors: Array(result[:message])
        }
      end