summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Holovaty <adrian@holovaty.com>2005-11-13 23:33:05 +0000
committerAdrian Holovaty <adrian@holovaty.com>2005-11-13 23:33:05 +0000
commit6e40d8c29f2b6ed926cf764f5c9cdce07bc9a069 (patch)
tree5a929453ea011a9398eb1c14e1187fcecf650c4a
parent8a0137446f27374795962bfa351e98929e15d40f (diff)
downloaddjango-6e40d8c29f2b6ed926cf764f5c9cdce07bc9a069.tar.gz
Fixed #783 -- Added AnonymousUser.id = None. Thanks, EABinGA
git-svn-id: http://code.djangoproject.com/svn/django/trunk@1221 bcc190cf-cafb-0310-a4f2-bffc1f526a37
-rw-r--r--django/parts/auth/anonymoususers.py2
-rw-r--r--docs/authentication.txt1
2 files changed, 3 insertions, 0 deletions
diff --git a/django/parts/auth/anonymoususers.py b/django/parts/auth/anonymoususers.py
index 03f294915c..b279d99d06 100644
--- a/django/parts/auth/anonymoususers.py
+++ b/django/parts/auth/anonymoususers.py
@@ -1,4 +1,6 @@
class AnonymousUser:
+ id = None
+
def __init__(self):
pass
diff --git a/docs/authentication.txt b/docs/authentication.txt
index 9aa581cf13..63beb43031 100644
--- a/docs/authentication.txt
+++ b/docs/authentication.txt
@@ -172,6 +172,7 @@ Anonymous users
``django.parts.auth.anonymoususers.AnonymousUser`` is a class that implements
the ``django.models.auth.users.User`` interface, with these differences:
+ * ``id`` is always ``None``.
* ``is_anonymous()`` returns ``True`` instead of ``False``.
* ``has_perm()`` always returns ``False``.
* ``set_password()``, ``check_password()``, ``set_groups()`` and