Capabilities change handler#3485
Conversation
CallWithChat bundle size is increased❗.
|
Chat bundle size is not changed.
|
There was a problem hiding this comment.
is newValue ever undefined?
There was a problem hiding this comment.
newValue is a Record and can't be undefined but can be empty. But I should be checking that turnVideoOn is in the Record with an isPresent value of false explicitly . I should not be potentially coercing a undefined to false. Fixed.
alkwa-msft
left a comment
There was a problem hiding this comment.
can we get a guarantee that when we are chaining calls that could be undefined with ? that we won't break at runtime? I would prefer to not have a repeat when we tried to deploy self host with raised hand and it broke due to us not checking correctly for capabilties?
8609471 to
bd60dab
Compare
| /* @conditional-compile-remove(capabilities) */ | ||
| private capabilitiesChanged(data: CapabilitiesChangeInfo): void { | ||
| if (data.newValue.turnVideoOn?.isPresent === false) { | ||
| this.stopCamera(); |
There was a problem hiding this comment.
Should we also be looking at the microphone state here to? Mute the participant if the capability is removed?
There was a problem hiding this comment.
The calling SDK mutes the mic when the unmute capability changed to not present but yeah we should also make sure on our side. Updated.
prabhjot-msft
left a comment
There was a problem hiding this comment.
looks good, hoping the existing comments are resolved before merge!
What
Why
How Tested
Local Interop testing.
https://github.com/Azure/communication-ui-library/assets/79475487/7b1b93b6-1399-4ede-a8ac-c4516dc08c53
Process & policy checklist
Is this a breaking change?