From bbd9bf4c5a58af80e2168c74201b29859b87426c Mon Sep 17 00:00:00 2001 From: Oliver Lazoroski Date: Thu, 16 Jan 2025 12:31:22 +0100 Subject: [PATCH] fix: update mute state only for video track on mobile --- packages/client/src/devices/InputMediaDeviceManager.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/client/src/devices/InputMediaDeviceManager.ts b/packages/client/src/devices/InputMediaDeviceManager.ts index b891f3992..f88da757f 100644 --- a/packages/client/src/devices/InputMediaDeviceManager.ts +++ b/packages/client/src/devices/InputMediaDeviceManager.ts @@ -3,6 +3,7 @@ import { Call } from '../Call'; import { CallingState } from '../store'; import { createSubscription } from '../store/rxUtils'; import { InputMediaDeviceManagerState } from './InputMediaDeviceManagerState'; +import { isMobile } from '../helpers/compatibility'; import { isReactNative } from '../helpers/platforms'; import { Logger } from '../coordinator/connection/types'; import { getLogger } from '../logger'; @@ -417,6 +418,7 @@ export abstract class InputMediaDeviceManager< } }; const createTrackMuteHandler = (muted: boolean) => () => { + if (!isMobile() || this.trackType !== TrackType.VIDEO) return; this.call.notifyTrackMuteState(muted, this.trackType).catch((err) => { this.logger('warn', 'Error while notifying track mute state', err); });