# frozen_string_literal: truemoduleMutationsmoduleNotesclassBase<BaseMutationfield:note,Types::Notes::NoteType,null: true,description: 'The note after mutation'privatedeffind_object(id:)GitlabSchema.object_from_id(id)enddefcheck_object_is_noteable!(object)unlessobject.is_a?(Noteable)raiseGitlab::Graphql::Errors::ResourceNotAvailable,'Cannot add notes to this resource'endenddefcheck_object_is_note!(object)unlessobject.is_a?(Note)raiseGitlab::Graphql::Errors::ResourceNotAvailable,'Resource is not a note'endendendendend