-
Notifications
You must be signed in to change notification settings - Fork 2.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[🐛] getInitialNotification - Map already consumed #5231
Comments
Hmmm that stack trace is from a release build and looks obfuscated. Any chance you can decode it or post a dev stack or an app.js that is self contained and steps to reproduce? The faster I can reproduce it the faster I can fix it |
I can't reproduce it in the dev environment, but I had received the error from a user on the production. And all I know is it happens on android 8.1 ( Motorola Moto G(5S) ). I have a device with Android 11, and I can't reproduce the error. UPD I have feedback from the user. He taps on a notification(on the lock screen) while the app in the background. The
componentDidMount() {
...
try {
const notification = await firebase.messaging().getInitialNotification();
if (notification) {
setTimeout(() => {
this._onReceivePushNotification(notification.data);
}, 1000);
}
} catch (error) {
logger.error(error);
}
firebase.messaging().onNotificationOpenedApp(({data}) => {
this._onReceivePushNotification(data);
});
...
} I hope it could help. |
Release 11.4.1 just went out with the change related to this among other fixes + features. Enjoy! 🚀 |
@mikehardy kindly reopen this ticket |
@inmogr I believe this is a duplicate of the similar but different new #5812 which should be fixed by #5814 Your feedback testing the related patch is requested: #5812 (comment) Should be released in a day or two but feedback would be great. |
@mikehardy will test the patch thanks |
Issue
Project Files
Javascript
Click To Expand
package.json
:firebase.json
for react-native-firebase v6:# N/A
iOS
Click To Expand
ios/Podfile
:AppDelegate.m
:// N/A
Android
Click To Expand
Have you converted to AndroidX?
android/gradle.settings
jetifier=true
for Android compatibility?jetifier
for react-native compatibility?android/build.gradle
:// N/A
android/app/build.gradle
:// N/A
android/settings.gradle
:// N/A
MainApplication.java
:// N/A
AndroidManifest.xml
:<!-- N/A -->
Environment
Click To Expand
react-native info
output:react-native-firebase
version you're using that has this issue:e.g. 5.4.3
Firebase
module(s) you're using that has the issue:e.g. Instance ID
TypeScript
?Y/N
&VERSION
React Native Firebase
andInvertase
on Twitter for updates on the library.The text was updated successfully, but these errors were encountered: