Skip to content

Commit

Permalink
Remove docstring.
Browse files Browse the repository at this point in the history
  • Loading branch information
luhn committed May 23, 2016
1 parent c351ca7 commit 1f14c40
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 14 deletions.
14 changes: 1 addition & 13 deletions aiohttp/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,19 +46,7 @@ def __new__(cls, login, password='', encoding='latin1'):
@classmethod
def decode(cls, auth_header, encoding='latin1'):
"""Create a :class:`BasicAuth` object from an ``Authorization`` HTTP
header.
:param auth_header: The value of the ``Authorization`` header.
:type auth_header: str
:param encoding: The character encoding used on the password.
:type encoding: str
:returns: The decoded authentication.
:rtype: :class:`BasicAuth`
:raises ValueError: if the headers are unable to be decoded.
"""
header."""
split = auth_header.strip().split(' ')
if len(split) == 2:
if split[0].strip().lower() != 'basic':
Expand Down
5 changes: 4 additions & 1 deletion docs/client_reference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -1290,10 +1290,13 @@ BasicAuth
e.g. *auth* parameter for :meth:`ClientSession.request`.


.. classmethod:: decode()
.. classmethod:: decode(auth_header, encoding='latin1')

Decode HTTP basic authentication credentials.

:param str auth_header: The ``Authorization`` header to decode.
:param str encoding: (optional) encoding ('latin1' by default)

:return: decoded authentication data, :class:`BasicAuth`.


Expand Down

0 comments on commit 1f14c40

Please sign in to comment.