React beginner here, I built my react native app using expo build:android -t app-bundle and I tried to upload it to the google play store and I got this error message:
Error
Your app has an APK with version code 1 that requests the following permissions: android.permission.READ_CONTACTS, android.permission.READ_PHONE_STATE, android.permission.RECORD_AUDIO, android.permission.CAMERA. Apps using these permissions in an APK are required to have a privacy policy set.
My app is just a weather app so i dont see why it would need contacts and recording audio.
app.json:
{
"expo": {
"name": "WeatherApp",
"slug": "WeatherApp",
"version": "1.0.0",
"orientation": "portrait",
"icon": "./assets/icon.png",
"splash": {
"image": "./assets/splash.png",
"resizeMode": "contain",
"backgroundColor": "#ffffff"
},
"updates": {
"fallbackToCacheTimeout": 0
},
"assetBundlePatterns": [
"**/*"
],
"ios": {
"supportsTablet": true
},
"android": {
"adaptiveIcon": {
"foregroundImage": "./assets/adaptive-icon.png",
"backgroundColor": "#FFFFFF"
},
"package": "com.company.weaher"
},
"web": {
"favicon": "./assets/favicon.png"
}
}
}
As per https://docs.expo.dev/versions/latest/config/app/#permissions, if you do not specify a permissions key under android in app.json (which is the case for any newly created Expo apps), Expo will use all the permissions supported by default.
Start by setting it to an empty array, as they state in the docs, and you will be fine.
Sometimes the Libraries you are using automatically requests for the permissions you mentioned. You just need to update your policies in the play store. Or If you don't use a library that requests for these permissions, then remove that library from your package.json file.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With