diff --git a/docs/ref/models/querysets.txt b/docs/ref/models/querysets.txt index 22ccda4b8e..f10f66425a 100644 --- a/docs/ref/models/querysets.txt +++ b/docs/ref/models/querysets.txt @@ -981,7 +981,7 @@ less ambiguous than storing a filtered result in the related manager's cache: >>> >>> # Recommended: >>> restaurants = Restaurant.objects.prefetch_related( - ... Prefetch('pizzas', to_attr='vegetarian_pizzas' queryset=queryset)) + ... Prefetch('pizzas', queryset=queryset, to_attr='vegetarian_pizzas')) >>> vegetarian_pizzas = restaurants[0].vegetarian_pizzas >>> >>> # Not recommended: