MCPcopy Create free account
hub / github.com/cli/cli / rootType

Function rootType

script/ghmock/graphqlcheck.go:174–183  ·  view source on GitHub ↗
(schema *ast.Schema, op ast.Operation)

Source from the content-addressed store, hash-verified

172}
173
174func rootType(schema *ast.Schema, op ast.Operation) *ast.Definition {
175 switch op {
176 case ast.Mutation:
177 return schema.Mutation
178 case ast.Subscription:
179 return schema.Subscription
180 default:
181 return schema.Query
182 }
183}
184
185// gqlWalker walks a response alongside the query that asked for it.
186type gqlWalker struct {

Callers 2

scaffoldGraphQLFunction · 0.85
checkGraphQLResponseFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected