From f1d1dde69657f2eb3f6b175560c8a9dc6daa8eff Mon Sep 17 00:00:00 2001 From: PavelRatushny Date: Tue, 10 Oct 2017 13:10:12 +0300 Subject: [PATCH] Fix #4445 --- OsmAnd/src/net/osmand/plus/search/QuickSearchHelper.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/OsmAnd/src/net/osmand/plus/search/QuickSearchHelper.java b/OsmAnd/src/net/osmand/plus/search/QuickSearchHelper.java index f2c5c9384d..88947203f9 100644 --- a/OsmAnd/src/net/osmand/plus/search/QuickSearchHelper.java +++ b/OsmAnd/src/net/osmand/plus/search/QuickSearchHelper.java @@ -11,6 +11,7 @@ import net.osmand.plus.OsmandApplication; import net.osmand.plus.R; import net.osmand.plus.helpers.SearchHistoryHelper; import net.osmand.plus.poi.PoiFiltersHelper; +import net.osmand.plus.poi.PoiUIFilter; import net.osmand.plus.resources.ResourceManager.ResourceListener; import net.osmand.search.SearchUICore; import net.osmand.search.SearchUICore.SearchResultCollection; @@ -86,7 +87,10 @@ public class QuickSearchHelper implements ResourceListener { for(CustomSearchPoiFilter udf : poiFilters.getUserDefinedPoiFilters()) { core.addCustomSearchPoiFilter(udf, 0); } - core.addCustomSearchPoiFilter(poiFilters.getLocalWikiPOIFilter(), 1); + PoiUIFilter localWikiPoiFilter = poiFilters.getLocalWikiPOIFilter(); + if (localWikiPoiFilter != null) { + core.addCustomSearchPoiFilter(localWikiPoiFilter, 1); + } core.addCustomSearchPoiFilter(poiFilters.getShowAllPOIFilter(), 1); }