Default service name if service name is not set on the session.

Pop service name off the session on sign out.
This commit is contained in:
Rebecca Law
2016-01-29 10:40:55 +00:00
parent 0dd20abbb3
commit 867ef7ad99
2 changed files with 5 additions and 3 deletions

View File

@@ -8,5 +8,7 @@ from app.main import main
@main.route('/sign-out', methods=(['GET']))
@login_required
def sign_out():
if session.get('service_name', None):
session.pop('service_name')
logout_user()
return redirect(url_for('main.index'))