File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -24,17 +24,19 @@ def get_operation_root_type(
2424 "Schema does not define the required query root type." , operation
2525 )
2626 return query_type
27- elif operation_type == OperationType .MUTATION :
27+
28+ if operation_type == OperationType .MUTATION :
2829 mutation_type = schema .mutation_type
2930 if not mutation_type :
3031 raise GraphQLError ("Schema is not configured for mutations." , operation )
3132 return mutation_type
32- elif operation_type == OperationType .SUBSCRIPTION :
33+
34+ if operation_type == OperationType .SUBSCRIPTION :
3335 subscription_type = schema .subscription_type
3436 if not subscription_type :
3537 raise GraphQLError ("Schema is not configured for subscriptions." , operation )
3638 return subscription_type
37- else :
38- raise GraphQLError (
39- "Can only have query, mutation and subscription operations." , operation
40- )
39+
40+ raise GraphQLError (
41+ "Can only have query, mutation and subscription operations." , operation
42+ )
You can’t perform that action at this time.
0 commit comments