Code

Opened 4 years ago

Closed 4 years ago

Last modified 3 years ago

#13263 closed (fixed)

code example typo in the documentation

Reported by: RicherPots Owned by: gabrielhurley
Component: Documentation Version: 1.1
Severity: Keywords:
Cc: Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

On the documentation page http://docs.djangoproject.com/en/dev/topics/db/queries/, the code example:

Blog.objects.filter(entry__author__name='Lennon')

is inconsistent with the Entry model:

class Entry(models.Model):
    #...
    authors = models.ManyToManyField(Author)

There are two other code snippets like the one above. For all of them, "authorname" should be replaced with "authorsname".

Attachments (1)

13263_docs_patch.diff (1.7 KB) - added by gabrielhurley 4 years ago.
corrects name of m2m field in query doc examples

Download all attachments as: .zip

Change History (5)

Changed 4 years ago by gabrielhurley

corrects name of m2m field in query doc examples

comment:1 Changed 4 years ago by gabrielhurley

  • Has patch set
  • milestone set to 1.2
  • Needs documentation unset
  • Needs tests unset
  • Owner changed from nobody to gabrielhurley
  • Patch needs improvement unset
  • Status changed from new to assigned
  • Triage Stage changed from Unreviewed to Accepted

Trivial patch. I even ran the example code before and after just to *really* be sure it was right ;-)

comment:2 Changed 4 years ago by anonymous

  • Triage Stage changed from Accepted to Ready for checkin

comment:3 Changed 4 years ago by jbronn

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [12927]) [1.1.X] Fixed #13263 -- Corrected field name typo in queries documentation examples. Thanks, RicherPots for bug report and gabrielhurley for the patch.

Backport of r12926 from trunk

comment:4 Changed 3 years ago by jacob

  • milestone 1.2 deleted

Milestone 1.2 deleted

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.