aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSamuel Tardieu <sam@rfc1149.net>2012-12-18 22:18:11 +0100
committerSamuel Tardieu <sam@rfc1149.net>2012-12-18 22:18:11 +0100
commit6fe12bd37037dff96ac66a6fe903241f04c21497 (patch)
tree1e607bcfb7a678eb7bc5883b56dca818ecd6a909
parentdfa622b179876ce94b3eb74c8623b4451adbbfd9 (diff)
downloadcgeo-6fe12bd37037dff96ac66a6fe903241f04c21497.zip
cgeo-6fe12bd37037dff96ac66a6fe903241f04c21497.tar.gz
cgeo-6fe12bd37037dff96ac66a6fe903241f04c21497.tar.bz2
Refactoring: remove pointless null checks
-rw-r--r--main/src/cgeo/geocaching/geopoint/Geopoint.java2
-rw-r--r--main/src/cgeo/geocaching/maps/google/GoogleMapProvider.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/main/src/cgeo/geocaching/geopoint/Geopoint.java b/main/src/cgeo/geocaching/geopoint/Geopoint.java
index 7d585ac..fb21a0c 100644
--- a/main/src/cgeo/geocaching/geopoint/Geopoint.java
+++ b/main/src/cgeo/geocaching/geopoint/Geopoint.java
@@ -259,7 +259,7 @@ public final class Geopoint implements ICoordinates, Parcelable {
if (this == obj) {
return true;
}
- if (obj == null || !(obj instanceof Geopoint)) {
+ if (!(obj instanceof Geopoint)) {
return false;
}
final Geopoint gp = (Geopoint) obj;
diff --git a/main/src/cgeo/geocaching/maps/google/GoogleMapProvider.java b/main/src/cgeo/geocaching/maps/google/GoogleMapProvider.java
index 6973338..dbe41d6 100644
--- a/main/src/cgeo/geocaching/maps/google/GoogleMapProvider.java
+++ b/main/src/cgeo/geocaching/maps/google/GoogleMapProvider.java
@@ -37,7 +37,7 @@ public final class GoogleMapProvider extends AbstractMapProvider {
}
public static boolean isSatelliteSource(final MapSource mapSource) {
- return mapSource != null && mapSource instanceof GoogleSatelliteSource;
+ return mapSource instanceof GoogleSatelliteSource;
}
@Override