Skip to content

Commit

Permalink
Add suggestion in backends docs, fix typo in backends.py
Browse files Browse the repository at this point in the history
  • Loading branch information
Bradley Gordon committed Apr 2, 2015
1 parent bfd7dd6 commit 4ab3445
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion authtools/backends.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def authenticate(self, username=None, password=None, **kwargs):
A word of caution. Use of this backend presupposes a way to ensure that users cannot
create usernames that differ only in case (e.g., joe@test.org and JOE@test.org). It is
advised that you use this backend in conjunction with the
EmailInsensitiveCreateUserForm provided in the forms module.
CaseInsensitiveEmailUserCreationForm provided in the forms module.
"""
if username is not None:
username = username.lower()
Expand Down
4 changes: 3 additions & 1 deletion docs/backends.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@ for how your :class:`authtool.models.User` class is authenticated.
.. warning:
Use of this mixin presupposes that all usernames are stored in their lowercase form, and
that there is no way to have usernames differing only in case. If usernames can differ in
case, this authentication backend mixin could cause errors in user authentication.
case, this authentication backend mixin could cause errors in user authentication. It is
advised that you use this mixin in conjuction with the
``CaseInsensitiveEmailUserCreationForm`` form provided in the ``forms`` module.
.. class:: CaseInsensitiveEmailModelBackend
A subclass of the ``CaseInsentiveEmailBackendMixin`` with
Expand Down

0 comments on commit 4ab3445

Please sign in to comment.