Skip to content

Commit

Permalink
When using the alert format, print the log and terminate the calkeep …
Browse files Browse the repository at this point in the history
…process.
  • Loading branch information
cloudwebrtc committed Jun 11, 2021
1 parent 1052eda commit 50652c4
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ios/Classes/CallKeep.m
Original file line number Diff line number Diff line change
Expand Up @@ -232,8 +232,14 @@ - (void)pushRegistry:(PKPushRegistry *)registry didReceiveIncomingPushWithPayloa
"has_video": false,
}
*/

NSDictionary *dic = payload.dictionaryPayload;

if (dic[@"aps"] != nil) {
NSLog(@"Do not use the 'alert' format for push type %@.", payload.type);
return;
}

NSString *uuid = dic[@"uuid"];
NSString *callerId = dic[@"caller_id"];
NSString *callerName = dic[@"caller_name"];
Expand Down

0 comments on commit 50652c4

Please sign in to comment.