Reputation: 301
In my project I have two permissions:
android.permission.USE_CREDENTIALS
android.permission.MANAGE_ACCOUNTS
that was removed in API Level 23 https://developer.android.com/sdk/api_diff/23/changes/android.Manifest.permission
Does that mean I can remove them if my targetSdkVersion is 23 or higher or minSdkVersion must be 23?
Upvotes: 2
Views: 1099
Reputation: 83018
No you need to add android:maxSdkVersion="22"
to these both permissions. Like below
<uses-permission android:name="android.permission.MANAGE_ACCOUNTS" android:maxSdkVersion="22" />
<uses-permission android:name="android.permission.USE_CREDENTIALS" android:maxSdkVersion="22"/>
Everything every Android Developer must know about new Android's Runtime Permission is a very good article for more info. And found Android M Permissions: Missing some of the old ones similar to your issue.
Upvotes: 1