forked from upstream-mirrors/OpenTracks
Waypoint requires a non-null location.
Remove setLocation() from Waypoint and TrackPoint.
This commit is contained in:
+1
-2
@@ -284,13 +284,12 @@ abstract class AbstractFileTrackImporter extends DefaultHandler implements Track
|
||||
return;
|
||||
}
|
||||
|
||||
Waypoint waypoint = new Waypoint();
|
||||
TrackPoint trackPoint = createTrackPoint();
|
||||
|
||||
if (!LocationUtils.isValidLocation(trackPoint.getLocation())) {
|
||||
throw new SAXException(createErrorMessage("Invalid location detected: " + trackPoint));
|
||||
}
|
||||
waypoint.setLocation(trackPoint.getLocation());
|
||||
Waypoint waypoint = new Waypoint(trackPoint.getLocation());
|
||||
|
||||
if (name != null) {
|
||||
waypoint.setName(name);
|
||||
|
||||
Reference in New Issue
Block a user