daily-co / react-native-daily-js

https://docs.daily.co/reference/rn-daily-js
BSD 2-Clause "Simplified" License
36 stars 13 forks source link

BUG - Camera permissions are requested even when in audio only mode #59

Closed james-cohen closed 4 weeks ago

james-cohen commented 1 month ago

Expected behavior

Create a call object for an audio only call, microphone permissions only are requested

Describe the bug (unexpected behavior)

Camera permissions are requested even thought video source is false

Steps to reproduce

Create new audio only call object on an Android device as described in guide:

      const newCallObject = Daily.createCallObject({
        videoSource: false,
        audioSource: true,
        startAudioOff: false,
      });

Camera permissions modal appears, sometimes before and sometimes after mic permissions

System information

* Device: Samsung Galaxy Z Flip 5 * OS, version: Android 14 * Browser, version: React Native
james-cohen commented 1 month ago

The issue may be due to the checkPermissions method in DailyNativeUtils.java - both camera and mic permissions seem to be requested regardless

filipi87 commented 1 month ago

Hi @james-cohen, thank you for reporting this. We were able to replicate the issue and plan to fix it before our next release. I’ll let you know once it's ready.

filipi87 commented 4 weeks ago

This issue has been fixed in react-native-daily-js version 0.70.0.

In order for it to properly work, the AndroidManifest.xml: