[Lada-commits] [PATCH 4 of 8] mittelpunkt might be null
Wald Commits
scm-commit at wald.intevation.org
Tue Dec 13 20:36:29 CET 2016
# HG changeset patch
# User Tom Gottfried <tom at intevation.de>
# Date 1481651722 -3600
# Node ID 563c7d18c45f34b51c6e708d530564471c38a255
# Parent 28a39466e4eb8985e4e8e8a8bb7417ab05b62973
mittelpunkt might be null.
diff -r 28a39466e4eb -r 563c7d18c45f src/main/java/de/intevation/lada/model/stammdaten/Verwaltungseinheit.java
--- a/src/main/java/de/intevation/lada/model/stammdaten/Verwaltungseinheit.java Tue Dec 13 17:24:06 2016 +0100
+++ b/src/main/java/de/intevation/lada/model/stammdaten/Verwaltungseinheit.java Tue Dec 13 18:55:22 2016 +0100
@@ -119,11 +119,15 @@
}
public Double getLatitude() {
- return this.mittelpunkt.getY();
+ return this.mittelpunkt != null
+ ? this.mittelpunkt.getY()
+ : null;
}
public Double getLongitude() {
- return this.mittelpunkt.getX();
+ return this.mittelpunkt != null
+ ? this.mittelpunkt.getX()
+ : null;
}
public String getNuts() {
More information about the Lada-commits
mailing list