Просмотр исходного кода

[RN] No CallKit failure on recoverable errors

master
Lyubo Marinov 8 лет назад
Родитель
Сommit
6f0fe06ba6
1 измененных файлов: 9 добавлений и 4 удалений
  1. 9
    4
      react/features/mobile/callkit/middleware.js

+ 9
- 4
react/features/mobile/callkit/middleware.js Просмотреть файл

135
 function _conferenceFailed(store, next, action) {
135
 function _conferenceFailed(store, next, action) {
136
     const result = next(action);
136
     const result = next(action);
137
 
137
 
138
-    const { callUUID } = action.conference;
139
-
140
-    if (callUUID) {
141
-        CallKit.reportCallFailed(callUUID);
138
+    // XXX Certain CONFERENCE_FAILED errors are recoverable i.e. they have
139
+    // prevented the user from joining a specific conference but the app may be
140
+    // able to eventually join the conference.
141
+    if (!action.error.recoverable) {
142
+        const { callUUID } = action.conference;
143
+
144
+        if (callUUID) {
145
+            CallKit.reportCallFailed(callUUID);
146
+        }
142
     }
147
     }
143
 
148
 
144
     return result;
149
     return result;

Загрузка…
Отмена
Сохранить