Open dhavalpanchani opened 2 years ago
Yes, I have tried these methods(endCall(), endAllCall()) to dismiss the call in "answerCall" listener but incoming UI is still displayed too. Have you solved this problem yet?
@trandinhhiep789 same here! did you find any solution ?
same here :( any solution ?
Hey guys,
I've been having the same issue, but managed to get it working with the "setCurrentCallActive"
You could add it on the answer event listener.
const answerCall = () => {
RNCallKeep.setCurrentCallActive("YOUR CALL UUID");
}
Hi there! A year later, we're still having this issue, after some digging on my side, it appears that the 'endCall' listener is being triggered immediately after displayIncomingCall
has been called. I've added logs here (#626) but didn't find any solution yet (@convertcompany solution did not work for me as the issue happens before the "answer call" button is tapped)
In my case, answerCall eventlistener is not added sometimes, and this mainly happens in production mode on android.
Isthere any way to check whether the eventlistener is added or not. I want to do something like, if eventlistener fails to add, i will try again until it suceeds, but as eventlisteners don't throw any error, i don't know any way to do so.
Bug report
Description
Answering the call from the incoming UI display on android was not navigating me to the app, the UI acted as if I had never answered the call.
I have tried with these methods(endCall(), endAllCall()) for dismiss the call in "answerCall" listener but incoming UI still displayed.
Steps to Reproduce
https://user-images.githubusercontent.com/25957550/158823274-f33e85f1-e170-4465-aa4f-9f42912976da.mp4
Here is my coding:
messaging().setBackgroundMessageHandler(handleRemoteMessage);
export async function handleRemoteMessage(notification) { console.log(
bg notification: ${JSON.stringify(notification)}, platform: ${ Platform.OS }, ${new Date().toDateString()}
, );const stringifiedData = notification?.data?.['pinpoint.jsonBody']; const parsedNotification = JSON.parse(stringifiedData || '{}'); const parsedData = JSON.parse(parsedNotification.data); RNCallKeep.displayIncomingCall( parsedData.meetingId, parsedData.callerName, parsedData.callerName, 'number', false, ); }
const onAnswerCall = async ({callUUID}) => { RNCallKeep.endCall(callUUID); // RNCallKeep.endAllCalls();
navigation.navigate('CallPage', { callFromNotification: true }); };
Versions
Logs