Skip to content

Commit

Permalink
fix: update mute state only for video track on mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
oliverlaz committed Jan 16, 2025
1 parent b07a9a6 commit bbd9bf4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions packages/client/src/devices/InputMediaDeviceManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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';
Expand Down Expand Up @@ -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);
});
Expand Down

0 comments on commit bbd9bf4

Please sign in to comment.