Skip to content
Browse files

Fixed #11419 -- Corrected a minor typo in the admin docs. Thanks to j…

…speis for the report.

git-svn-id: bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
1 parent 36954a0 commit b96e55e811aadda25f190878d5c30d0ac745f810 @freakboy3742 freakboy3742 committed
Showing with 1 addition and 1 deletion.
  1. +1 −1 docs/ref/contrib/admin/index.txt
2 docs/ref/contrib/admin/index.txt
@@ -794,7 +794,7 @@ return a subset of objects for this foreign key field based on the user::
class MyModelAdmin(admin.ModelAdmin):
def formfield_for_foreignkey(self, db_field, request, **kwargs):
if == "car":
- kwargs["queryset"] = Car.object.filter(owner=request.user)
+ kwargs["queryset"] = Car.objects.filter(owner=request.user)
return db_field.formfield(**kwargs)
return super(MyModelAdmin, self).formfield_for_foreignkey(db_field, request, **kwargs)

0 comments on commit b96e55e

Please sign in to comment.
Something went wrong with that request. Please try again.