Page MenuHomePhabricator

D10014.diff
No OneTemporary

D10014.diff

diff --git a/native/push/ios.js b/native/push/ios.js
--- a/native/push/ios.js
+++ b/native/push/ios.js
@@ -75,15 +75,17 @@
return !permissions.alert || !permissions.badge || !permissions.sound;
}
+export type CoreIOSNotificationBackgroundData = {
+ +messageInfosArray: $ReadOnlyArray<string>,
+};
+
function getCommIOSNotificationsEventEmitter(): NativeEventEmitter<
$ReadOnly<{
remoteNotificationsRegistered: [{ +deviceToken: ?string }],
remoteNotificationsRegistrationFailed: [void],
notificationReceivedForeground: [CoreIOSNotificationData],
notificationOpened: [CoreIOSNotificationData],
- notificationReceivedBackground: [
- { +messageInfosArray: $ReadOnlyArray<string> },
- ],
+ notificationReceivedBackground: [CoreIOSNotificationBackgroundData],
}>,
> {
return new NativeEventEmitter(CommIOSNotifications);
diff --git a/native/push/push-handler.react.js b/native/push/push-handler.react.js
--- a/native/push/push-handler.react.js
+++ b/native/push/push-handler.react.js
@@ -68,6 +68,7 @@
iosPushPermissionResponseReceived,
CommIOSNotifications,
getCommIOSNotificationsEventEmitter,
+ type CoreIOSNotificationBackgroundData,
} from './ios.js';
import {
type MessageListParams,
@@ -591,7 +592,9 @@
);
};
- iosBackgroundNotificationReceived = backgroundData => {
+ iosBackgroundNotificationReceived = (
+ backgroundData: CoreIOSNotificationBackgroundData,
+ ) => {
const convertedMessageInfos = backgroundData.messageInfosArray
.flatMap(convertNotificationMessageInfoToNewIDSchema)
.filter(Boolean);

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 9, 1:32 AM (21 h, 4 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2447249
Default Alt Text
D10014.diff (1 KB)

Event Timeline