openvidu-browser: do not add default audio track to screen media steam if screen audio source

pull/828/head
pabloFuente 2023-10-16 16:51:29 +02:00
parent 1e416325b6
commit 2e07e25df7
1 changed files with 1 additions and 1 deletions

View File

@ -504,7 +504,7 @@ export class Publisher extends StreamManager {
const getMediaSuccess = async (mediaStream: MediaStream, definedAudioConstraint) => {
this.clearPermissionDialogTimer(startTime, timeForDialogEvent);
if (this.stream.isSendScreen() && this.stream.isSendAudio()) {
if (this.stream.isSendScreen() && this.properties.audioSource !== 'screen' && this.stream.isSendAudio()) {
// When getting desktop as user media audio constraint must be false. Now we can ask for it if required
constraintsAux.audio = definedAudioConstraint;
constraintsAux.video = false;