From 32be4e4b90294ec1a5e4f36855fd748b4bc81797 Mon Sep 17 00:00:00 2001 From: Patrick Dowler Date: Tue, 24 Sep 2024 14:41:06 -0700 Subject: [PATCH] extra NPE prevention check --- .../main/java/org/opencadc/vault/NodePersistenceImpl.java | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/vault/src/main/java/org/opencadc/vault/NodePersistenceImpl.java b/vault/src/main/java/org/opencadc/vault/NodePersistenceImpl.java index 54dd0348..3b0f4821 100644 --- a/vault/src/main/java/org/opencadc/vault/NodePersistenceImpl.java +++ b/vault/src/main/java/org/opencadc/vault/NodePersistenceImpl.java @@ -521,11 +521,7 @@ private class ChildNodeWrapper implements ResourceIterator { @Override public boolean hasNext() { - return !closedForException && childIter.hasNext(); - //if (childIter != null) { - // return childIter.hasNext(); - //} - //return false; + return !closedForException && childIter != null && childIter.hasNext(); } @Override