Change check for empty category
This commit is contained in:
parent
45a4f9df6d
commit
e63524f1e7
1 changed files with 2 additions and 1 deletions
|
@ -18,6 +18,7 @@ import net.osmand.plus.MapMarkersHelper.MapMarker;
|
||||||
import net.osmand.plus.R;
|
import net.osmand.plus.R;
|
||||||
import net.osmand.plus.activities.MapActivity;
|
import net.osmand.plus.activities.MapActivity;
|
||||||
import net.osmand.plus.dashboard.DashLocationFragment;
|
import net.osmand.plus.dashboard.DashLocationFragment;
|
||||||
|
import net.osmand.util.Algorithms;
|
||||||
|
|
||||||
import java.text.SimpleDateFormat;
|
import java.text.SimpleDateFormat;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
|
@ -160,7 +161,7 @@ public class MapMarkersActiveAdapter extends RecyclerView.Adapter<MapMarkerItemV
|
||||||
String day = new SimpleDateFormat("d", Locale.getDefault()).format(date);
|
String day = new SimpleDateFormat("d", Locale.getDefault()).format(date);
|
||||||
descr = month + " " + day;
|
descr = month + " " + day;
|
||||||
}
|
}
|
||||||
if (marker.wptPt != null && marker.wptPt.category != null) {
|
if (marker.wptPt != null && !Algorithms.isEmpty(marker.wptPt.category)) {
|
||||||
descr = marker.wptPt.category + ", " + descr;
|
descr = marker.wptPt.category + ", " + descr;
|
||||||
}
|
}
|
||||||
holder.description.setText(descr);
|
holder.description.setText(descr);
|
||||||
|
|
Loading…
Reference in a new issue