aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
Diffstat (limited to 'main')
-rw-r--r--main/src/cgeo/geocaching/connector/ec/ECApi.java4
1 files changed, 1 insertions, 3 deletions
diff --git a/main/src/cgeo/geocaching/connector/ec/ECApi.java b/main/src/cgeo/geocaching/connector/ec/ECApi.java
index f91bcdb..fe93846 100644
--- a/main/src/cgeo/geocaching/connector/ec/ECApi.java
+++ b/main/src/cgeo/geocaching/connector/ec/ECApi.java
@@ -156,7 +156,6 @@ public class ECApi {
}
private static List<Geocache> importCachesFromJSON(final HttpResponse response) {
-
if (response != null) {
try {
final String data = Network.getResponseDataAlways(response);
@@ -179,7 +178,6 @@ public class ECApi {
}
return Collections.emptyList();
-
}
private static Geocache parseCache(final JSONObject response) {
@@ -192,7 +190,7 @@ public class ECApi {
cache.setType(getCacheType(response.getString("type")));
cache.setDifficulty((float) response.getDouble("difficulty"));
cache.setTerrain((float) response.getDouble("terrain"));
- cache.setFound(response.getInt("found") == 1 ? true : false);
+ cache.setFound(response.getInt("found") == 1);
DataStore.saveCache(cache, EnumSet.of(SaveFlag.SAVE_CACHE));
} catch (final JSONException e) {