Please provide the following:
- SDK Version: 39
- Platforms(Android/iOS/web/all): Android
Im working in expo SDK 39 and with android 5.1, whenever i use “Location.getCurrentPositionAsync({ accuracy: Location.Accuracy.Highest, })” i get the error message “Location provider is unavailable. Make sure that location services are enabled.”
CODE BELOW:
let { status } = await Location.requestPermissionsAsync();
if (status !== 'granted') {
console.log('Permission to access location was denied');
} else {
try {
let location = await Location.getCurrentPositionAsync({ accuracy: Location.Accuracy.Highest, });
if (location) {
console.log('location',location)
}
} catch (err) {
console.log('error', err)
}
}