[Feature-Request, iOS] Add completion for fulfilling action of 'performEndCallAction' delegate
See original GitHub issueHey guys! Thank you all for the great project. It’s absolutely must-have for calling apps based on react-native!
In our project we use the event ‘endCall’ to let know a server that incoming call was declined on the client side. The problem is when user declines an incoming call by system notification at the top of screen on iOS, while having the closed app, OS soon pauses all JS execution until a user opens the application.
I has been debugging the issue and finally figured out that implementation of performEndCallAction
https://github.com/react-native-webrtc/react-native-callkeep/blob/2a4b0c0dc134021bedd85f57a2cc7dc68a717430/ios/RNCallKeep/RNCallKeep.m#L1051-L1059
fulfills the end call action right after emitting the event to JS-runtime. For example, if fulfillment will be delayed for 5 seconds then RN-side would be able to process properly notifying the server about declining call in my case.
Issue Analytics
- State:
- Created a year ago
- Comments:6
Top GitHub Comments
If someone else is looking for alternative approach you can get inspiration from my gist - https://gist.github.com/Hesowcharov/1e3e0dcdc6806fb0b234f01d7d9233a6
up: I’ve implemented with the approach above and it seems working flawlessly! When the iOS app receives voip-push and boots the application, while a user immediately declines the incoming call with the CallKit UI notification, RN app manages to setup and send a request to the server and only then fulfill the end call action (the notification hangs on a few seconds and wait to be dismissed on fulfillment).