CE-1654 - do chicken-egg session before the OTHER call to finalizeCustomizeSession too...

This commit is contained in:
2024-09-10 10:51:21 -05:00
parent 3cc0cfd86c
commit 161591405b

View File

@ -247,10 +247,7 @@ public class Auth0AuthenticationModule implements QAuthenticationModuleInterface
////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////
// allow customizer to do custom things here, if so desired // // allow customizer to do custom things here, if so desired //
////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////
if(getCustomizer() != null) finalCustomizeSession(qInstance, qSession);
{
getCustomizer().finalCustomizeSession(qInstance, qSession);
}
return (qSession); return (qSession);
} }
@ -311,14 +308,7 @@ public class Auth0AuthenticationModule implements QAuthenticationModuleInterface
////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////
// allow customizer to do custom things here, if so desired // // allow customizer to do custom things here, if so desired //
////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////
if(getCustomizer() != null) finalCustomizeSession(qInstance, qSession);
{
QContext.withTemporaryContext(QContext.capture(), () ->
{
QContext.setQSession(getChickenAndEggSession());
getCustomizer().finalCustomizeSession(qInstance, qSession);
});
}
return (qSession); return (qSession);
} }
@ -364,6 +354,23 @@ public class Auth0AuthenticationModule implements QAuthenticationModuleInterface
/***************************************************************************
**
***************************************************************************/
private void finalCustomizeSession(QInstance qInstance, QSession qSession)
{
if(getCustomizer() != null)
{
QContext.withTemporaryContext(QContext.capture(), () ->
{
QContext.setQSession(getChickenAndEggSession());
getCustomizer().finalCustomizeSession(qInstance, qSession);
});
}
}
/******************************************************************************* /*******************************************************************************
** Insert a session as a new record into userSession table ** Insert a session as a new record into userSession table
*******************************************************************************/ *******************************************************************************/