mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-05 10:53:28 -05:00
Use session.clear() sign-out.
NOTE: you can not test that the session is cleared out by checking the session cookie does not exist on the index page, because ItsDangerousSession will create a new session when it hits the index page. The unit test confirms that the session has been cleared.
This commit is contained in:
@@ -8,7 +8,6 @@ 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')
|
||||
session.clear()
|
||||
logout_user()
|
||||
return redirect(url_for('main.index'))
|
||||
|
||||
Reference in New Issue
Block a user