Class: GraphQL::Batch::MutationFieldExtension
- Inherits:
-
Schema::FieldExtension
- Object
- Schema::FieldExtension
- GraphQL::Batch::MutationFieldExtension
- Defined in:
- lib/graphql/batch/mutation_field_extension.rb
Instance Method Summary collapse
Instance Method Details
#resolve(object:, arguments:, **_rest) ⇒ Object
3 4 5 6 7 8 9 10 |
# File 'lib/graphql/batch/mutation_field_extension.rb', line 3 def resolve(object:, arguments:, **_rest) GraphQL::Batch::Executor.current.clear begin ::Promise.sync(yield(object, arguments)) ensure GraphQL::Batch::Executor.current.clear end end |