Skip to content

Commit

Permalink
restore NPE check
Browse files Browse the repository at this point in the history
Signed-off-by: Olivier Lamy <olamy@apache.org>
  • Loading branch information
olamy committed Jun 28, 2024
1 parent c525a34 commit 02bf999
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -182,11 +182,11 @@ public SessionData doLoad(String id) throws Exception
if (sessionDocument == null)
return null;

boolean valid = (Boolean)sessionDocument.get(__VALID);
Boolean valid = (Boolean)sessionDocument.get(__VALID);

if (LOG.isDebugEnabled())
LOG.debug("id={} valid={}", id, valid);
if (!valid)
if (valid == null || !valid)
return null;

Object version = MongoUtils.getNestedValue(sessionDocument, getContextSubfield(__VERSION));
Expand Down

0 comments on commit 02bf999

Please sign in to comment.