Fix Wpt issue

This commit is contained in:
Victor Shcherb 2015-06-08 00:20:56 +02:00
parent c198eea126
commit a72f9c32cd

View file

@ -481,9 +481,9 @@ public class FavouritesDbHelper {
name = ""; name = "";
} }
// old way to store the category, in name. // old way to store the category, in name.
if ("".equals(categoryName.trim()) && (c = p.name.lastIndexOf('_')) != -1) { if ("".equals(categoryName.trim()) && (c = name.lastIndexOf('_')) != -1) {
categoryName = p.name.substring(c + 1); categoryName = name.substring(c + 1);
name = p.name.substring(0, c); name = name.substring(0, c);
} }
FavouritePoint fp = new FavouritePoint(p.lat, p.lon, name, categoryName); FavouritePoint fp = new FavouritePoint(p.lat, p.lon, name, categoryName);
fp.setDescription(p.desc); fp.setDescription(p.desc);