for some reason my code causes my program to crash. does anyone know why or how to fix it?
NSLog(@"here");
CLLocation *location = [locationManager location];
[mapView removeAnnotations:mapView.annotations];
NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults];
CLLocationCoordinate2D workingCoordinate = [location coordinate];
NSLog(@" this is %@", workingCoordinate.latitude);
it makes it to the first NSLog, but somewhere between the first and second it crashes. My guess is that it has to do with the CLLocation *location line.