From 2cd8fa31d44c7eb095cb5f0879fcfaffffd813c0 Mon Sep 17 00:00:00 2001 From: demasterr Date: Mon, 11 Mar 2019 16:03:48 +0100 Subject: [PATCH] Removed identical check in equals Changes: * In CatalogTag.java the equals method contained to identical evaluations of equals with an OR. Here I assumed the `mId` to be unique and, therefore, no more checks are required. Alternatively the `mLocalizedName` could be included in the equality, as well as the `mColor`. --- android/src/com/mapswithme/maps/bookmarks/data/CatalogTag.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/android/src/com/mapswithme/maps/bookmarks/data/CatalogTag.java b/android/src/com/mapswithme/maps/bookmarks/data/CatalogTag.java index fd25569527..ba20345f7e 100644 --- a/android/src/com/mapswithme/maps/bookmarks/data/CatalogTag.java +++ b/android/src/com/mapswithme/maps/bookmarks/data/CatalogTag.java @@ -72,7 +72,7 @@ public class CatalogTag implements Parcelable if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; CatalogTag that = (CatalogTag) o; - return mId.equals(that.mId) || mId.equals(that.mId); + return mId.equals(that.mId); } @Override