Fix crash in camera position (#3847)
This commit is contained in:
@@ -108,6 +108,10 @@ final class LocationAnimatorCoordinator {
|
||||
LatLng previousCameraLatLng = currentCameraPosition.target;
|
||||
float previousCameraBearing = normalize((float) currentCameraPosition.bearing);
|
||||
|
||||
if (previousCameraLatLng == null) {
|
||||
previousCameraLatLng = previousLayerLatLng;
|
||||
}
|
||||
|
||||
// generate targets for layer
|
||||
LatLng[] latLngValues = getLatLngValues(previousLayerLatLng, newLocations);
|
||||
Float[] bearingValues = getBearingValues(previousLayerBearing, newLocations);
|
||||
|
||||
Reference in New Issue
Block a user