Remove unnecessary check

This commit is contained in:
Vitaliy 2020-09-18 13:35:47 +03:00
parent e07d6486bf
commit 407492d230

View file

@ -235,9 +235,7 @@ public class TransportStopController extends MenuController {
for (TransportStop stop : transportStops) {
stop.setTransportStopAggregated(stopAggregated);
String stopName = stop.getName().toLowerCase();
if (((stopName.startsWith(amenity.getName())
|| stopName.contains(amenityName)
|| amenityName.contains(stopName))
if (((stopName.contains(amenityName) || amenityName.contains(stopName))
&& (nearestStop == null
|| nearestStop.getLocation().equals(stop.getLocation())))
|| stop.getLocation().equals(loc)) {