Browse Source

[iOS] Fix checking if a track is local in ithe CallKit middleware

Not all TRACK_ actions include the `local` attribute, so use the underlying
`jitsiTrack` to check it.
j8
Saúl Ibarra Corretgé 7 years ago
parent
commit
42b85f73bd
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      react/features/mobile/callkit/middleware.js

+ 2
- 2
react/features/mobile/callkit/middleware.js View File

@@ -380,11 +380,11 @@ function _setCallKitSubscriptions({ getState }, next, action) {
380 380
  */
381 381
 function _syncTrackState({ getState }, next, action) {
382 382
     const result = next(action);
383
-    const { track } = action;
383
+    const { jitsiTrack } = action.track;
384 384
     const state = getState();
385 385
     const conference = getCurrentConference(state);
386 386
 
387
-    if (track.local && conference && conference.callUUID) {
387
+    if (jitsiTrack.isLocal() && conference && conference.callUUID) {
388 388
         const tracks = state['features/base/tracks'];
389 389
         const muted = isLocalTrackMuted(tracks, MEDIA_TYPE.AUDIO);
390 390
 

Loading…
Cancel
Save