Authored by Taylor Trimble

Use localized NSLocationWhenInUseUsageDescription key for assert.

Closes #548.

From Apple’s Bundle Programming Guide:

The NSBundle class provides the objectForInfoDictionaryKey: and
infoDictionary methods for retrieving information from the Info.plist
file. The objectForInfoDictionaryKey: method returns the localized
value for a key and is the preferred method to call. The infoDictionary
method returns an NSDictionary with all of the keys from the property
list; however, it does not return any localized values for these keys.
For more information, see the NSBundle Class Reference.
... ... @@ -3321,7 +3321,7 @@
//
if ([CLLocationManager instancesRespondToSelector:@selector(requestWhenInUseAuthorization)])
{
NSAssert([[[NSBundle mainBundle] infoDictionary] valueForKey:@"NSLocationWhenInUseUsageDescription"], @"For iOS 8 and above, your app must have a value for NSLocationWhenInUseUsageDescription in its Info.plist");
NSAssert([[NSBundle mainBundle] objectForInfoDictionaryKey:@"NSLocationWhenInUseUsageDescription"], @"For iOS 8 and above, your app must have a value for NSLocationWhenInUseUsageDescription in its Info.plist");
[_locationManager requestWhenInUseAuthorization];
}
#endif
... ...