trying to fix docstring formatting errors

This commit is contained in:
Kyle Mahan 2015-12-16 18:12:31 +00:00
parent d50ea9b465
commit 8e73330bd0
2 changed files with 13 additions and 6 deletions

View File

@ -63,5 +63,5 @@ https://indiewebcamp.com/IndieAuth and https://indiewebcamp.com/Micropub
API API
--- ---
.. automodule:: mf2util .. automodule:: flask_micropub
:members: :members:

View File

@ -27,13 +27,16 @@ DEFAULT_AUTH_URL = 'https://indieauth.com/auth'
class MicropubClient: class MicropubClient:
"""Flask-Micropub provides support for IndieAuth/Micropub """Flask-Micropub provides support for IndieAuth/Micropub
authentication and authorization. authentication and authorization.
"""
def __init__(self, app=None, client_id=None):
"""Initialize the Micropub extension
Args: Args:
app (flask.Flask, optional): the flask application to extend. app (flask.Flask, optional): the flask application to extend.
client_id (string, optional): the IndieAuth client id, will be displayed client_id (string, optional): the IndieAuth client id, will be displayed
when the user is asked to authorize this client. when the user is asked to authorize this client.
""" """
def __init__(self, app=None, client_id=None):
self.app = app self.app = app
self.client_id = client_id self.client_id = client_id
if app is not None: if app is not None:
@ -305,9 +308,13 @@ class AuthResponse:
Attributes: Attributes:
me (string): The authenticated user's URL. This will be non-None if and me (string): The authenticated user's URL. This will be non-None if and
only if the user was successfully authenticated. only if the user was successfully authenticated.
micropub_endpoint (string): The endpoint to POST micropub requests to. micropub_endpoint (string): The endpoint to POST micropub requests to.
access_token (string): The authorized user's micropub access token. access_token (string): The authorized user's micropub access token.
state (string): The optional state that was passed to authorize. state (string): The optional state that was passed to authorize.
error (string): describes the error encountered if any. It is possible error (string): describes the error encountered if any. It is possible
that the authentication step will succeed but the access token step that the authentication step will succeed but the access token step
will fail, in which case me will be non-None, and error will describe will fail, in which case me will be non-None, and error will describe