summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorMalcolm Tredinnick <malcolm.tredinnick@gmail.com>2008-03-20 06:35:53 +0000
committerMalcolm Tredinnick <malcolm.tredinnick@gmail.com>2008-03-20 06:35:53 +0000
commit6417f5247b98d5457d5b62c313cd8e1edeaa5e63 (patch)
tree1e6dbc314b065e577b1d36d3756803a4f83edab4 /docs
parent649cdf907d5d23290caf3cc7e34426c39dfa4159 (diff)
Merged the tests and documentation from #4720 to support the changes in [7295].
Thanks, Andy Gayton. Fixed #4720. Refs #5855. git-svn-id: http://code.djangoproject.com/svn/django/trunk@7328 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'docs')
-rw-r--r--docs/syndication_feeds.txt7
1 files changed, 7 insertions, 0 deletions
diff --git a/docs/syndication_feeds.txt b/docs/syndication_feeds.txt
index ebd6af26f8..f86acfe54d 100644
--- a/docs/syndication_feeds.txt
+++ b/docs/syndication_feeds.txt
@@ -245,6 +245,13 @@ request to the URL ``/rss/beats/0613/``:
subclass of ``ObjectDoesNotExist``. Raising ``ObjectDoesNotExist`` in
``get_object()`` tells Django to produce a 404 error for that request.
+ **New in Django development version:** The ``get_object()`` method also
+ has a chance to handle the ``/rss/beats/`` url. In this case, ``bits``
+ will be an empty list. In our example, ``len(bits) != 1`` and an
+ ``ObjectDoesNotExist`` exception will be raised, so ``/rss/beats/`` will
+ generate a 404 page. But you can handle this case however you like. For
+ example you could generate a combined feed for all beats.
+
* To generate the feed's ``<title>``, ``<link>`` and ``<description>``,
Django uses the ``title()``, ``link()`` and ``description()`` methods. In
the previous example, they were simple string class attributes, but this