def setup_for_flask_views(auth, app, urloptions):
    urloptions = urloptions or {}

    if 'sign_in' in auth.views:
        url_sign_in = eval_url(auth.url_sign_in)
        app.route(
            url_sign_in,
            methods=['GET', 'POST'],
            endpoint='{prefix}{name}'.format(
                prefix=auth.views_prefix, name='auth_sign_in'),
            **urloptions
        )(auth.auth_sign_in)

    if 'sign_out' in auth.views:
        url_sign_out = eval_url(auth.url_sign_out)
        app.route(
            url_sign_out,
            methods=['GET', 'POST'],
            endpoint='{prefix}{name}'.format(
                prefix=auth.views_prefix, name='auth_sign_out'),
            **urloptions
        )(auth.auth_sign_out)

    if 'change_password' in auth.views:
        url_change_password = eval_url(auth.url_change_password)
        app.route(
            url_change_password,
            methods=['GET', 'POST'],
            endpoint='{prefix}{name}'.format(
                prefix=auth.views_prefix, name='auth_change_password'),
            **urloptions
        )(auth.auth_change_password)

    if 'reset_password' in auth.views:
        url_reset_password = eval_url(auth.url_reset_password)
        app.route(
            url_reset_password,
            methods=['GET', 'POST'],
            endpoint='{prefix}{name}'.format(
                prefix=auth.views_prefix, name='auth_reset_password'),
            **urloptions
        )(auth.auth_reset_password)
        app.route(
            url_reset_password.rstrip('/') + '/<token>/',
            methods=['GET', 'POST'],
            endpoint='{prefix}{name}'.format(
                prefix=auth.views_prefix, name='auth_reset_password'),
            **urloptions
        )(auth.auth_reset_password)
dataset/ETHPy150Open jpscaletti/authcode/authcode/setups/setup_for_flask.py/setup_for_flask_views/original