From 2f2673dc5eb36a03d92c0d74dc902b910dce1da0 Mon Sep 17 00:00:00 2001 From: harshadbhatia Date: Tue, 24 Oct 2017 22:52:05 +1100 Subject: [PATCH] Update documentation in tutorial to avoid positional argument error --- docs/tutorial-plain.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/tutorial-plain.rst b/docs/tutorial-plain.rst index 592f244..63d6470 100644 --- a/docs/tutorial-plain.rst +++ b/docs/tutorial-plain.rst @@ -157,10 +157,10 @@ Create ``cookbook/ingredients/schema.py`` and type the following: all_categories = graphene.List(CategoryType) all_ingredients = graphene.List(IngredientType) - def resolve_all_categories(self, info, **kwargs): + def resolve_all_categories(self, info, *args, **kwargs): return Category.objects.all() - def resolve_all_ingredients(self, info, **kwargs): + def resolve_all_ingredients(self, info, *args, **kwargs): # We can easily optimize query count in the resolve method return Ingredient.objects.select_related('category').all()