Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UX/UI fixes #11

Merged
merged 4 commits into from
Jun 27, 2017
Merged

UX/UI fixes #11

merged 4 commits into from
Jun 27, 2017

Conversation

mvidalgarcia
Copy link
Member

No description provided.

@@ -42,7 +42,6 @@ def make_app():
'SQLALCHEMY_TRACK_MODIFICATIONS': False,
'MULTIPASS_LOGIN_SELECTOR_TEMPLATE': 'login_selector.html',
'MULTIPASS_LOGIN_FORM_TEMPLATE': 'login_form.html',
'MULTIPASS_SUCCESS_ENDPOINT': 'auth.index'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should stay. see the logic in multipass to get the next url:

    try:
        return session.pop('_multipass_next_url')
    except KeyError:
        return url_for(current_app.config['MULTIPASS_SUCCESS_ENDPOINT'])

@@ -33,7 +33,8 @@ def get_server_fields(server):
def login_required():
whitelist = current_app.config['USER_WHITELIST']
if 'user' not in session or session['user'] not in whitelist.get(session.get('provider'), set()):
return multipass.logout(url_for('auth.login'), clear_session=True)
next_url = request.full_path
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd use request.full_path.rstrip('?') to get rid of the ugly trailing ? if there's no query string

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants