aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/cgeo/geocaching/cgCache.java
diff options
context:
space:
mode:
authorBananeweizen <bananeweizen@gmx.de>2012-01-31 07:32:40 +0100
committerBananeweizen <bananeweizen@gmx.de>2012-01-31 07:32:40 +0100
commitcff161c259ff85c603478a95e7dcd6c01d66e9e5 (patch)
tree7ac0788454a313ab2c90005e07178aeb3a539cc9 /main/src/cgeo/geocaching/cgCache.java
parent7fba2c26fd9203eb9cde0997bca231b63f11c2c4 (diff)
downloadcgeo-cff161c259ff85c603478a95e7dcd6c01d66e9e5.zip
cgeo-cff161c259ff85c603478a95e7dcd6c01d66e9e5.tar.gz
cgeo-cff161c259ff85c603478a95e7dcd6c01d66e9e5.tar.bz2
fix #1071: FC with unknown container size
Diffstat (limited to 'main/src/cgeo/geocaching/cgCache.java')
-rw-r--r--main/src/cgeo/geocaching/cgCache.java10
1 files changed, 9 insertions, 1 deletions
diff --git a/main/src/cgeo/geocaching/cgCache.java b/main/src/cgeo/geocaching/cgCache.java
index 432bd93..9fdaaaf 100644
--- a/main/src/cgeo/geocaching/cgCache.java
+++ b/main/src/cgeo/geocaching/cgCache.java
@@ -507,6 +507,9 @@ public class cgCache implements ICache {
@Override
public CacheSize getSize() {
+ if (size == null) {
+ return CacheSize.UNKNOWN;
+ }
return size;
}
@@ -986,7 +989,12 @@ public class cgCache implements ICache {
}
public void setSize(CacheSize size) {
- this.size = size;
+ if (size == null) {
+ this.size = CacheSize.UNKNOWN;
+ }
+ else {
+ this.size = size;
+ }
}
public void setDifficulty(float difficulty) {