Kaydet (Commit) cc8a800d authored tarafından Bryan Helmig's avatar Bryan Helmig Kaydeden (comit) Baptiste Mispelon

[1.7.x] Fixed minor syntax error in Queryset docs

Backport of f2eea960 from master.
üst dda62244
......@@ -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:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment