forked from eatvio/eatvio_app
feat(video_calls): fixed ios and HMS pushes for calls
This commit is contained in:
@@ -86,6 +86,20 @@ import flutter_foreground_task
|
||||
}
|
||||
|
||||
let dict = payload.dictionaryPayload
|
||||
if let pushType = (
|
||||
dict["type"] as? String
|
||||
?? dict["notification_type"] as? String
|
||||
?? dict["event"] as? String
|
||||
?? dict["action"] as? String
|
||||
)?.lowercased().replacingOccurrences(of: "-", with: "_"),
|
||||
pushType.contains("video_call"),
|
||||
pushType.contains("end") || pushType.contains("cancel")
|
||||
{
|
||||
SwiftFlutterCallkitIncomingPlugin.sharedInstance?.endAllCalls()
|
||||
completion()
|
||||
return
|
||||
}
|
||||
|
||||
let nameCaller = (dict["nameCaller"] as? String)
|
||||
?? (dict["caller_name"] as? String)
|
||||
?? (dict["callerName"] as? String)
|
||||
|
||||
Reference in New Issue
Block a user