Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does google analytics add wakelock permission?

So i just added Google Analytics to my app's activities. When uploading the new .apk to the play store, it told me that the app now requires 1 more Permission: WAKE_LOCK.

Now I'm 100% sure that this permission is not in my manifest, so it has to be added by Google Analytics. Is there a way to disable that? Or would that ruin google analytics?

Thanks in advance!

like image 778
The_Vinci Avatar asked Nov 23 '15 13:11

The_Vinci


1 Answers

Try using the "tools" namespace and then explicitly removing the "WAKE_LOCK" permission. I've written up a full explanation here but, in summary:

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
        xmlns:tools="http://schemas.android.com/tools">

    ...
    ...
    <uses-permission android:name="android.permission.WAKE_LOCK" tools:node="remove" />
like image 87
Ian Avatar answered Sep 19 '22 03:09

Ian