Don't override session during auth

Looks like we try to override the session even if we don't auth, let's
not do that.

Change-Id: I520c3d020e3415c5737af7912bddf34931190d65
Closes-Bug: #1748751
This commit is contained in:
Thomas Herve 2018-02-12 14:50:41 +01:00 committed by yatin
parent 1bf4a0c8be
commit f5816f1d79
1 changed files with 4 additions and 3 deletions

View File

@ -59,9 +59,10 @@ class Client(object):
else:
auth_response = {}
# If the session was None and we're using keystone auth, it will be
# created by the auth_handler.
session = auth_response.pop('session', None)
if session is None:
# If the session was None and we're using keystone auth, it will be
# created by the auth_handler.
session = auth_response.pop('session', None)
req.update(auth_response)