Method: GraphQL::StaticValidation::TypeStack::FragmentWithTypeStrategy#push
- Defined in:
- lib/graphql/static_validation/type_stack.rb
#push(stack, node) ⇒ Object
56 57 58 59 60 61 62 63 64 65 66 67 |
# File 'lib/graphql/static_validation/type_stack.rb', line 56 def push(stack, node) object_type = if node.type stack.schema.get_type(node.type.name) else stack.object_types.last end if !object_type.nil? object_type = object_type.unwrap end stack.object_types.push(object_type) push_path_member(stack, node) end |