diff options
Diffstat (limited to 'web')
-rw-r--r-- | web/main.js | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/web/main.js b/web/main.js index 3e2c0a7..ac790d7 100644 --- a/web/main.js +++ b/web/main.js @@ -258,18 +258,17 @@ var guiHandlers = { samlData = jsonObj.data; if (!samlData) return {'tid': message.tid, 'sid': message.sid, 'code': -2, 'message': 'IdP proxy did not return any SAML data'}; if (!samlData.userData) return {'tid': message.tid, 'sid': message.sid, 'code': -3, 'message': 'IdP proxy did not return any SAML user data'}; - message.saml_data = samlData.userData; // add the data from SAML authentication, and forward everything to Python + + // we need the SAML data to be able to perform global logout (saml_logout action) + session.samlData = samlData; + + // add the data from SAML authentication, and forward everything to Python + message.saml_data = samlData.userData; return sendDataToPython(message); }); } - p.then(function (jsonObj) { - if ((jsonObj.code === 0) || (jsonObj.code === 1)) { - // we need the SAML data to be able to perform global logout (saml_logout action) - session.samlData = samlData; - } - session.send(jsonObj); - }) + p.then(session.send) .catch(function (e) { var m = 'Error while trying to process the SAML request using the identity server: ' + e; logException(m, e); |