Skip to content

Commit

Permalink
Replace "!instanceof" by "is not an instance of"
Browse files Browse the repository at this point in the history
  • Loading branch information
matthias-ronge committed Aug 14, 2024
1 parent 4e93607 commit 8f57b28
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public void onLogoutSuccess(HttpServletRequest request, HttpServletResponse resp
UserDetails user = (UserDetails) principal;
ServiceManager.getSessionService().expireSessionsOfUser(user);
} else {
logger.warn(MessageFormat.format("Cannot expire session: {0} !instanceof UserDetails",
logger.warn(MessageFormat.format("Cannot expire session: {0} is not an instance of UserDetails",
Helper.getObjectDescription(principal)));
}
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@ public void sessionDestroyed(HttpSessionEvent se) {
if (principal instanceof SecurityUserDetails) {
expireSessionsOfUser((SecurityUserDetails) principal);
} else {
logger.warn(MessageFormat.format("Cannot expire session: {0} !instanceof SecurityUserDetails",
logger.warn(MessageFormat.format("Cannot expire session: {0} is not an instance of SecurityUserDetails",
Helper.getObjectDescription(principal)));
}
} else {
logger.warn(MessageFormat.format("Cannot expire session: {0} !instanceof SecurityContextImpl",
logger.warn(MessageFormat.format("Cannot expire session: {0} is not an instance of SecurityContextImpl",
Helper.getObjectDescription(securityContextObject)));
}
}
Expand Down

0 comments on commit 8f57b28

Please sign in to comment.