mirror of
https://github.com/electron/electron.git
synced 2026-01-09 15:38:08 -05:00
fix: base::DictionaryValue usage in APNS notifs (#34897)
This commit is contained in:
@@ -39,7 +39,7 @@ class PushNotifications
|
||||
PushNotifications& operator=(const PushNotifications&) = delete;
|
||||
|
||||
#if BUILDFLAG(IS_MAC)
|
||||
void OnDidReceiveAPNSNotification(const base::DictionaryValue& user_info);
|
||||
void OnDidReceiveAPNSNotification(const base::Value::Dict& user_info);
|
||||
void ResolveAPNSPromiseSetWithToken(const std::string& token_string);
|
||||
void RejectAPNSPromiseSetWithError(const std::string& error_message);
|
||||
#endif
|
||||
|
||||
@@ -53,7 +53,7 @@ void PushNotifications::UnregisterForAPNSNotifications() {
|
||||
}
|
||||
|
||||
void PushNotifications::OnDidReceiveAPNSNotification(
|
||||
const base::DictionaryValue& user_info) {
|
||||
const base::Value::Dict& user_info) {
|
||||
Emit("received-apns-notification", user_info);
|
||||
}
|
||||
|
||||
|
||||
@@ -193,7 +193,7 @@ static NSDictionary* UNNotificationResponseToNSDictionary(
|
||||
electron::api::PushNotifications::Get();
|
||||
if (push_notifications) {
|
||||
electron::api::PushNotifications::Get()->OnDidReceiveAPNSNotification(
|
||||
electron::NSDictionaryToDictionaryValue(userInfo));
|
||||
electron::NSDictionaryToValue(userInfo));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user