title: -[CLLocationManager requestWhenInUseAuthorization] or -[CLLocationManager requestAlwaysAuthorization] error
body: <p>This is my code, showing both the alert and the blue dot for the current position on the map:</p>
  
  <p><strong>MapName.h</strong></p>
  
  <pre><code>#import &lt;UIKit/UIKit.h&gt;
  #import &lt;MapKit/MapKit.h&gt;
  #import &lt;CoreLocation/CoreLocation.h&gt;
  
  
  @interface MapName : UIViewController &lt;MKMapViewDelegate, CLLocationManagerDelegate&gt;
  
  @property (strong, nonatomic) IBOutlet MKMapView *MapName;
  @property (strong, nonatomic) CLLocationManager *locationManager;
  
  @end
  </code></pre>
  
  <p><strong>MapName.m</strong></p>
  
  <pre><code>- (void)viewDidLoad
  {
  [super viewDidLoad];
  
  self.locationManager = [[CLLocationManager alloc]init];
  self.locationManager.delegate = self;
  if ([self.locationManager respondsToSelector:@selector(requestWhenInUseAuthorization)]) {
      [self.locationManager requestWhenInUseAuthorization];
  }
  [self.locationManager startUpdatingLocation];
  
  //Center the map
  [self gotoLocation];
  
  //Show current position
  _MapName.showsUserLocation = YES;
  
  }
  </code></pre>
  
  <p>I've added the key <code>NSLocationWhenIsUseUsageDescription</code> as a string to the Info.plist.
  I'm still getting the same error on Xcode.</p>