mustangproject
mustangproject copied to clipboard
Nullpointer Exception import zugferd
java.lang.NullPointerException at org.mustangproject.ZUGFeRD.TransactionCalculator.getVATPercentAmountMap(TransactionCalculator.java:187) at org.mustangproject.ZUGFeRD.TransactionCalculator.getGrandTotal(TransactionCalculator.java:44) at org.mustangproject.ZUGFeRD.ZUGFeRDInvoiceImporter.extractInvoice(ZUGFeRDInvoiceImporter.java:349)
Mustang-CLI-2.5.3.jar
Hi, Steps to reproduce? E.g. the invoice? Thanks and kind regards Jochen
Hi, invoice is not public.
currentAllowance.getTaxPercent() is null -->NPE
solution:
old code:
ATAmount theAmount = hm.get(currentAllowance.getTaxPercent().stripTrailingZeros());
new code:
ATAmount theAmount = currentAllowance.getTaxPercent()==null?null:hm.get(currentAllowance.getTaxPercent().stripTrailingZeros());
Does the invoice validate?
Yes, invoice validates Please contact me by mail, I can send the invoice.pdf
I don't have your email, but mine is listed on https://www.mustangproject.org/contact-us/ :-)