Closed
Description
In react version 0.62
I am calling PermissionsAndroid with custom message and title but app just show the default message. I am using the code given below.
const requestLocationPermission = async () => {
try {
const granted = await PermissionsAndroid.request(
PermissionsAndroid.PERMISSIONS.ACCESS_FINE_LOCATION,
{
title: "LocationPermission",
message:
"Our app need to access your location" +
"so that we can use to separate photo on asset .",
buttonNeutral: "Ask Me Later",
buttonNegative: "Cancel",
buttonPositive: "OK"
}
);
if (granted === PermissionsAndroid.RESULTS.GRANTED) {
console.log("You can use the location");
} else {
console.log("Location permission denied");
}
} catch (err) {
console.warn(err);
}
};