From 32b8c62ec95e849c24d6deaecaa5e9ae8338faf4 Mon Sep 17 00:00:00 2001 From: Jaya Allamsetty <54324652+jallamsetty1@users.noreply.github.com> Date: Fri, 23 Sep 2022 13:45:51 -0400 Subject: [PATCH] fix(face-landmarks) Do not start detection on muted tracks --- react/features/face-landmarks/middleware.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/react/features/face-landmarks/middleware.ts b/react/features/face-landmarks/middleware.ts index 39837a878..186756b20 100644 --- a/react/features/face-landmarks/middleware.ts +++ b/react/features/face-landmarks/middleware.ts @@ -63,9 +63,9 @@ MiddlewareRegistry.register((store: IStore) => (next: Function) => (action: any) return next(action); } case TRACK_ADDED: { - const { jitsiTrack: { isLocal, videoType } } = action.track; + const { jitsiTrack: { isLocal, muted, videoType } } = action.track; - if (videoType === 'camera' && isLocal()) { + if (videoType === 'camera' && isLocal() && !muted) { // need to pass this since the track is not yet added in the store FaceLandmarksDetector.startDetection(store, action.track); }