Skip to content

Commit

Permalink
Fix nullpointer on hasChild("resource")
Browse files Browse the repository at this point in the history
  • Loading branch information
dotasek committed Oct 9, 2024
1 parent d714041 commit 850542b
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ public static boolean allEntriesAreHistoryProvenance(Element resource) throws Un
}
List<Element> entries = resource.getChildrenByName("entry");
for (Element be : entries) {
if (!"Provenance".equals(be.getNamedChild("resource").fhirType())) {
if (!be.hasChild("resource") || !"Provenance".equals(be.getNamedChild("resource").fhirType())) {
return false;
}
}
Expand Down

0 comments on commit 850542b

Please sign in to comment.