Fix exception of selecting sightseeing layer

This commit is contained in:
vshcherb 2013-11-24 18:17:49 +01:00
parent 105beb6976
commit 783ff9c46b

View file

@ -590,7 +590,7 @@ public class MapActivityLayers {
String filterId;
if (which == 0) {
filterId = PoiFiltersHelper.getOsmDefinedFilterId(null);
} else if (which <= userDefined.size()) {
} else if (which <= userDefined.size() + 1) {
filterId = userDefined.get(which - 2).getFilterId();
} else {
filterId = PoiFiltersHelper.getOsmDefinedFilterId(categories[which - userDefined.size() - 2]);