Hi Tommy,
Thanks for your answer. The default is fine, but I can’t override it.
Sorry, I think I should have made it clearer that this is a bug report. So here it is with the correct template.
Description
In the React Native SDK, a JoinSessionConfig
can be used to set whether or not a user is muted when joining a session. On iOS, these options are called the SessionContext.
Errors
Setting the mute
option has no effect and the audio will always remain muted after joining the session.
Which React Native Video SDK version?
NPM Package: @zoom1234/react-native-videosdk: 1.1.1
iOS Framework: zoom-video-sdk-iOS-1.1.1
Video SDK Code Snippets
Joining a session from the React Native SDK (code from the official SDK example):
await zoom.joinSession({
sessionName: params.sessionName,
sessionPassword: params.sessionPassword,
token: token,
userName: params.displayName,
audioOptions: {
connect: true,
mute: false, // ← should have an effect
},
videoOptions: {
localVideoOn: true,
},
});
To Reproduce(If applicable)
Steps to reproduce the behavior:
- Use the official
react-native-zoom-video-sdk/example
- Change the audioOption to
mute: false
(which it already is).
- Start the app.
- Join a session.
- The local user is muted.
Screenshots
Both screenshots from debugging in Xcode of the same debugging session with the config shown above.
The incoming NSDictionary audioOptionConfig
shows the correct values.
After retrieving the vales from the dictionary the mute
value is still true
.
Smartphone (please complete the following information):
- Device: iPhone XS Max
- OS: iOS 15.1
Additional context
Boolean values have to be interpreted with boolValue
when retrieved from an NSDictionary. I’ve patched the code of my local Pod to use boolValue
and it works as expected now.
audioOption.mute = [[audioOptionConfig valueForKey:@"mute"] boolValue];
The same must be applied to the other boolean options as well.