Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Work without WRITE_CONTACTS permission #25

Closed
noamraph opened this issue Jul 9, 2021 · 4 comments
Closed

Work without WRITE_CONTACTS permission #25

noamraph opened this issue Jul 9, 2021 · 4 comments

Comments

@noamraph
Copy link

noamraph commented Jul 9, 2021

Hi,

I only intend to read contacts. I see that in order not to get a "permission denied" result, I have to add both READ_CONTACTS and WRITE_CONTACTS to AndroidManifest.xml.

Is it possible to only request the READ_CONTACTS permission, if I don't intend to modify contacts?

Thanks,
Noam

@sils
Copy link

sils commented Aug 18, 2021

I've had the same problem with the builtin permission request feature. However, since I'm already using a different permission requesting plugin for other functionalities, I switched to that which solved the issue for me, as that apparently is fine with requesting read only permission.

@joachim-quis
Copy link
Contributor

Hi @noamraph – if you don't intend to modify contacts, you can specify READ_CONTACTS only and stay away from update/delete methods, and it should work fine. Let me know if it's not the case.

@joachim-quis
Copy link
Contributor

Oh, I misunderstood your question, you're referring to FlutterContacts.requestPermission(). Indeed at the moment it requests both read and write. I will change that in the next upgrade, so we can request one without the other.

@joachim-quis
Copy link
Contributor

Done in version 1.1.1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants