Commit 20dbbc5f authored by Tim Graham's avatar Tim Graham
Browse files

[1.6.x] Fixed #22453 -- Corrected DoesNotExist message in docs.

Thanks Eugenio Cano-Manuel.

Backport of eefad142 from master
parent 9510e96d
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -102,7 +102,7 @@ necessary:
    >>> Reporter.objects.get(id=2)
    Traceback (most recent call last):
        ...
    DoesNotExist: Reporter matching query does not exist. Lookup parameters were {'id': 2}
    DoesNotExist: Reporter matching query does not exist.

    # Create an article.
    >>> from datetime import date
+1 −1
Original line number Diff line number Diff line
@@ -673,7 +673,7 @@ Save these changes and start a new Python interactive shell by running
    >>> Poll.objects.get(id=2)
    Traceback (most recent call last):
        ...
    DoesNotExist: Poll matching query does not exist. Lookup parameters were {'id': 2}
    DoesNotExist: Poll matching query does not exist.

    # Lookup by a primary key is the most common case, so Django provides a
    # shortcut for primary-key exact lookups.