Skip to content

Commit

Permalink
LDEV-3478 call onSessionEnd with on sessionRotate
Browse files Browse the repository at this point in the history
  • Loading branch information
zspitzer committed Jan 12, 2024
1 parent a2f431e commit 0fa5a1f
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions core/src/main/java/lucee/runtime/type/scope/ScopeContext.java
Original file line number Diff line number Diff line change
Expand Up @@ -999,6 +999,15 @@ public void invalidateUserScope(PageContextImpl pc, boolean migrateSessionData,
Map<String, Scope> sessionContext = getSubMap(cfSessionContexts, appContext.getName());
UserScope oldSession = (UserScope) sessionContext.get(pc.getCFID());

ApplicationListener listener = factory.getConfig().getApplicationListener();
try {
listener.onSessionEnd(factory, appContext.getName(), pc.getCFID());
}
catch (Throwable t) {
ExceptionUtil.rethrowIfNecessary(t);
ExceptionHandler.log(pc.getCfmlFactory(), Caster.toPageException(t));
}

// remove Scopes completly
removeCFSessionScope(pc);
removeClientScope(pc);
Expand Down

0 comments on commit 0fa5a1f

Please sign in to comment.