From 2b61cfe008aa44d592f886e1e485fa1c4e23be13 Mon Sep 17 00:00:00 2001 From: jstaerk Date: Mon, 25 Oct 2021 09:33:47 +0200 Subject: [PATCH] added another non-null condition --- .../java/org/mustangproject/ZUGFeRD/ZUGFeRDInvoiceImporter.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/src/main/java/org/mustangproject/ZUGFeRD/ZUGFeRDInvoiceImporter.java b/library/src/main/java/org/mustangproject/ZUGFeRD/ZUGFeRDInvoiceImporter.java index 7cee84d0..e16b9aa9 100644 --- a/library/src/main/java/org/mustangproject/ZUGFeRD/ZUGFeRDInvoiceImporter.java +++ b/library/src/main/java/org/mustangproject/ZUGFeRD/ZUGFeRDInvoiceImporter.java @@ -290,7 +290,7 @@ public class ZUGFeRDInvoiceImporter extends ZUGFeRDImporter { if (chargeNodeChilds.item(chargeChildIndex).getLocalName().equals("ChargeIndicator")) { NodeList indicatorChilds = chargeNodeChilds.item(chargeChildIndex).getChildNodes(); for (int indicatorChildIndex = 0; indicatorChildIndex < indicatorChilds.getLength(); indicatorChildIndex++) { - if (indicatorChilds.item(indicatorChildIndex).getLocalName().equals("Indicator")) { + if ((indicatorChilds.item(indicatorChildIndex).getLocalName()!=null)&&(indicatorChilds.item(indicatorChildIndex).getLocalName().equals("Indicator"))) { isCharge = indicatorChilds.item(indicatorChildIndex).getTextContent().equalsIgnoreCase("true"); } }