Android studio adds unwanted permission after running application on real device

后端 未结 3 931
我在风中等你
我在风中等你 2020-11-22 04:55

After running application on device application required unwanted location permission that is not mention in manifest file. While when I am running same code from my friend

3条回答
  •  长发绾君心
    2020-11-22 05:51

    For the new versions of Google Play Service libraries, you have to add only the required part of the library as a dependency. For instance, if you are using Google Play Service library just to display ads from Admob, then replace

    compile 'com.google.android.gms:play-services:+'
    

    with

    compile 'com.google.android.gms:play-services-ads:7.5.0'
    

    This will remove the other unnecessary permissions.

提交回复
热议问题