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

Don't try to get phone account if self managed when creating a connection #685

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

donaldkwong
Copy link

We want to use CallKeep without requesting READ_PHONE_STATE permissions on Android, which should be possible if we're in self managed state. However, the connection creation code in VoiceConnectionService always tries to get the phone account, which requires that permission to be granted. This diff adds a check to see if we're in self managed mode and, if so, don't try to get the phone account.

@donaldkwong donaldkwong deleted the dwong/self_managed branch April 20, 2023 22:14
@wilmxre
Copy link

wilmxre commented May 30, 2023

@donaldkwong hey man, why did you close this PR?

@donaldkwong donaldkwong restored the dwong/self_managed branch July 14, 2023 20:34
@donaldkwong donaldkwong reopened this Jul 14, 2023
@manuquentin
Copy link
Contributor

Thanks @donaldkwong, can you add a little bit of documentation for this behaviour ?

@donaldkwong
Copy link
Author

@manuquentin , what were you thinking of in terms of documentation? Changes to README.md or code comments?

@manuquentin
Copy link
Contributor

manuquentin commented Jul 31, 2023

Can you put changes in the README please ?

@donaldkwong
Copy link
Author

Honestly not sure what to write in the README since this feels more like a bug fix than a feature, but I added a description of the behavior.

@donaldkwong
Copy link
Author

I don't have permission to merge this PR. Can someone do it for me?

@Bayramito
Copy link

We want to use CallKeep without requesting READ_PHONE_STATE permissions on Android, which should be possible if we're in self managed state. However, the connection creation code in VoiceConnectionService always tries to get the phone account, which requires that permission to be granted. This diff adds a check to see if we're in self managed mode and, if so, don't try to get the phone account.

hey @donaldkwong is this going to help me to use some functions in android without calling setup, functions like setAudioRoute ?

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

Successfully merging this pull request may close these issues.

4 participants