浏览代码

bugfix(ios) changes the participantInfo completion handler reference to strong.

When the method was called from Swift they were collected before calling them.
master
tmoldovan8x8 4 年前
父节点
当前提交
ef6b641802
没有帐户链接到提交者的电子邮件
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2
    2
      ios/sdk/src/ExternalAPI.m

+ 2
- 2
ios/sdk/src/ExternalAPI.m 查看文件

30
 
30
 
31
 __attribute__((constructor))
31
 __attribute__((constructor))
32
 static void initializeViewsMap() {
32
 static void initializeViewsMap() {
33
-    participantInfoCompletionHandlers = [NSMapTable strongToWeakObjectsMapTable];
33
+    participantInfoCompletionHandlers = [NSMapTable strongToStrongObjectsMapTable];
34
 }
34
 }
35
 
35
 
36
 RCT_EXPORT_MODULE();
36
 RCT_EXPORT_MODULE();
160
     NSString *completionHandlerId = [[NSUUID UUID] UUIDString];
160
     NSString *completionHandlerId = [[NSUUID UUID] UUIDString];
161
     NSDictionary *data = @{ @"requestId": completionHandlerId};
161
     NSDictionary *data = @{ @"requestId": completionHandlerId};
162
     
162
     
163
-    [participantInfoCompletionHandlers setObject:completionHandler forKey:completionHandlerId];
163
+    [participantInfoCompletionHandlers setObject:[completionHandler copy] forKey:completionHandlerId];
164
     
164
     
165
     [self sendEventWithName:retrieveParticipantsInfoAction body:data];
165
     [self sendEventWithName:retrieveParticipantsInfoAction body:data];
166
 }
166
 }

正在加载...
取消
保存