only update user location once

This commit is contained in:
Justin R. Miller
2014-06-01 18:04:31 -07:00
parent 38dd25a85a
commit 58ff49198f

View File

@@ -204,9 +204,9 @@ llmr::Settings_NSUserDefaults *settings = nullptr;
if ([latestLocation distanceFromLocation:[[CLLocation alloc] initWithLatitude:self.mapView.centerCoordinate.latitude longitude:self.mapView.centerCoordinate.longitude]] > 100)
{
[self.mapView setCenterCoordinate:CLLocationCoordinate2DMake(latestLocation.coordinate.latitude, latestLocation.coordinate.longitude) zoomLevel:17 animated:YES];
[self.locationManager stopUpdatingLocation];
}
[self.locationManager stopUpdatingLocation];
}
#pragma clang diagnostic pop