We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7768d14 commit a7034baCopy full SHA for a7034ba
examples/starwars/schema.py
@@ -16,7 +16,7 @@ class Meta:
16
interfaces = (relay.Node, )
17
18
@classmethod
19
- def get_node(cls, id, context, info):
+ def get_node(cls, info, id):
20
node = get_ship(id)
21
return node
22
@@ -34,7 +34,7 @@ class Meta:
34
35
36
37
38
return get_faction(id)
39
40
@@ -48,9 +48,7 @@ class Input:
48
faction = graphene.Field(Faction)
49
50
51
- def mutate_and_get_payload(cls, input, context, info):
52
- ship_name = input.get('ship_name')
53
- faction_id = input.get('faction_id')
+ def mutate_and_get_payload(cls, root, info, ship_name, faction_id, client_mutation_id=None):
54
ship = create_ship(ship_name, faction_id)
55
faction = get_faction(faction_id)
56
return IntroduceShip(ship=ship, faction=faction)
0 commit comments