build ( body: body, author: context ) if comment.
feature_enabled? ( :remove_example_mutations ) end argument :body, String, required: true argument :post_id, ID, required: true field :comment, Types:: Comment, null: true field :errors, , null: false def resolve ( body:, post_id: ) post = Post.
visible? ( context ) # Hide mutation based on feature flag :remove_example_mutations super & ! context. # In this example sketch, `Types::Comment` and `Types::UserErrors` are visible but not `Mutations::CreateComment` class Types:: UserErrors < GraphQL:: Schema:: Object field :message, String, null: false field :field, , null: true end class Mutations:: CreateComment < Mutations:: BaseMutation def self.