Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Fixed #12195 -- Clarified cache documentation to rename 'timeout_seco…

…nds' to 'timeout'. Thanks, galund and timo

git-svn-id: http://code.djangoproject.com/svn/django/trunk@12183 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 7789e9c006901cdc33fcdfc98d932eb06e912b93 1 parent 5ce16c7
@adrianholovaty adrianholovaty authored
Showing with 4 additions and 3 deletions.
  1. +4 −3 docs/topics/cache.txt
View
7 docs/topics/cache.txt
@@ -470,14 +470,15 @@ automatically created from the ``CACHE_BACKEND`` setting::
>>> from django.core.cache import cache
-The basic interface is ``set(key, value, timeout_seconds)`` and ``get(key)``::
+The basic interface is ``set(key, value, timeout)`` and ``get(key)``::
>>> cache.set('my_key', 'hello, world!', 30)
>>> cache.get('my_key')
'hello, world!'
-The ``timeout_seconds`` argument is optional and defaults to the ``timeout``
-argument in the ``CACHE_BACKEND`` setting (explained above).
+The ``timeout`` argument is optional and defaults to the ``timeout``
+argument in the ``CACHE_BACKEND`` setting (explained above). It's the number of
+seconds the value should be stored in the cache.
If the object doesn't exist in the cache, ``cache.get()`` returns ``None``::

0 comments on commit 7789e9c

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