Mercurial > dive4elements > river
changeset 3417:ed9689fbcd26
FixA: Prevent NPE when exporting parameters.
flys-artifacts/trunk@5070 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Thu, 19 Jul 2012 15:25:46 +0000 |
parents | f14206b4b688 |
children | 21c1d1d25919 |
files | flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/exports/fixings/ParametersExporter.java |
diffstat | 2 files changed, 7 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog Thu Jul 19 15:20:51 2012 +0000 +++ b/flys-artifacts/ChangeLog Thu Jul 19 15:25:46 2012 +0000 @@ -1,3 +1,8 @@ +2012-07-19 Sascha L. Teichmann <sascha.teichmann@intevation.de> + + * src/main/java/de/intevation/flys/exports/fixings/ParametersExporter.java: + Prevent NPE. + 2012-07-19 Sascha L. Teichmann <sascha.teichmann@intevation.de> * src/main/java/de/intevation/flys/artifacts/model/fixings/FixFacetUtils.java:
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/fixings/ParametersExporter.java Thu Jul 19 15:20:51 2012 +0000 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/fixings/ParametersExporter.java Thu Jul 19 15:25:46 2012 +0000 @@ -50,7 +50,9 @@ Object data = ((CalculationResult)d).getData(); if (!(data instanceof FixAnalysisResult)) { log.warn("Invalid data stored in result."); + return; } + FixAnalysisResult result = (FixAnalysisResult)data; parametersList.add(result.getParameters()); }