@react-native-firebase/messaging 21.10.1 → 21.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,16 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ ## [21.12.0](https://github.com/invertase/react-native-firebase/compare/v21.11.0...v21.12.0) (2025-03-03)
7
+
8
+ **Note:** Version bump only for package @react-native-firebase/messaging
9
+
10
+ ## [21.11.0](https://github.com/invertase/react-native-firebase/compare/v21.10.1...v21.11.0) (2025-02-20)
11
+
12
+ ### Bug Fixes
13
+
14
+ - **messaging, ios:** serialize access to background handler state ([4d166ca](https://github.com/invertase/react-native-firebase/commit/4d166ca77bcc1a6c53b4a7e652654eb000d7f0fe))
15
+
6
16
  ## [21.10.1](https://github.com/invertase/react-native-firebase/compare/v21.10.0...v21.10.1) (2025-02-18)
7
17
 
8
18
  ### Bug Fixes
@@ -163,14 +163,16 @@
163
163
  // If app is in background state, register background task to guarantee async queues aren't
164
164
  // frozen.
165
165
  sharedInstance.backgroundTaskId = [application beginBackgroundTaskWithExpirationHandler:^{
166
- if (sharedInstance.backgroundTaskId != UIBackgroundTaskInvalid) {
167
- [application endBackgroundTask:sharedInstance.backgroundTaskId];
168
- sharedInstance.backgroundTaskId = UIBackgroundTaskInvalid;
169
- }
166
+ dispatch_get_main_queue(), ^{
167
+ if (sharedInstance.backgroundTaskId != UIBackgroundTaskInvalid) {
168
+ [application endBackgroundTask:sharedInstance.backgroundTaskId];
169
+ sharedInstance.backgroundTaskId = UIBackgroundTaskInvalid;
170
+ }
171
+ };
170
172
  }];
171
173
 
172
174
  dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(25 * NSEC_PER_SEC)),
173
- dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_HIGH, 0), ^{
175
+ dispatch_get_main_queue(), ^{
174
176
  if (sharedInstance.completionHandler) {
175
177
  sharedInstance.completionHandler(UIBackgroundFetchResultNewData);
176
178
  sharedInstance.completionHandler = nil;
@@ -220,7 +220,7 @@ RCT_EXPORT_METHOD(getIsHeadless : (RCTPromiseResolveBlock)resolve : (RCTPromiseR
220
220
  }
221
221
 
222
222
  RCT_EXPORT_METHOD(completeNotificationProcessing) {
223
- dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_HIGH, 0), ^{
223
+ dispatch_get_main_queue(), ^{
224
224
  RNFBMessagingAppDelegate *appDelegate = [RNFBMessagingAppDelegate sharedInstance];
225
225
  if (appDelegate.completionHandler) {
226
226
  appDelegate.completionHandler(UIBackgroundFetchResultNewData);
@@ -230,7 +230,7 @@ RCT_EXPORT_METHOD(completeNotificationProcessing) {
230
230
  [[UIApplication sharedApplication] endBackgroundTask:appDelegate.backgroundTaskId];
231
231
  appDelegate.backgroundTaskId = UIBackgroundTaskInvalid;
232
232
  }
233
- });
233
+ };
234
234
  }
235
235
 
236
236
  RCT_EXPORT_METHOD(requestPermission
package/lib/version.js CHANGED
@@ -1,2 +1,2 @@
1
1
  // Generated by genversion.
2
- module.exports = '21.10.1';
2
+ module.exports = '21.12.0';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@react-native-firebase/messaging",
3
- "version": "21.10.1",
3
+ "version": "21.12.0",
4
4
  "author": "Invertase <oss@invertase.io> (http://invertase.io)",
5
5
  "description": "React Native Firebase - React Native Firebase provides native integration of Firebase Cloud Messaging (FCM) for both Android & iOS. FCM is a cost free service, allowing for server-device and device-device communication. The React Native Firebase Messaging module provides a simple JavaScript API to interact with FCM.",
6
6
  "main": "lib/index.js",
@@ -24,7 +24,7 @@
24
24
  "messaging"
25
25
  ],
26
26
  "peerDependencies": {
27
- "@react-native-firebase/app": "21.10.1",
27
+ "@react-native-firebase/app": "21.12.0",
28
28
  "expo": ">=47.0.0"
29
29
  },
30
30
  "devDependencies": {
@@ -38,5 +38,5 @@
38
38
  "publishConfig": {
39
39
  "access": "public"
40
40
  },
41
- "gitHead": "153637d27bb98b1f44a4b27fe1f8ec133bdbfb6d"
41
+ "gitHead": "00a5540bc2d8007858dd01903d8f8c171587a766"
42
42
  }