-
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
fix(messaging, android): repair crash handling remote notifications #5236
fix(messaging, android): repair crash handling remote notifications #5236
Conversation
WritableNativeMap has a check to see if it is consumed or not when it is used, to prevent resolving a Promise in native code then attempting to modify it. We may use the same WritableNativeMap object twice though when handling deferred initial notifications. Crash repair is to store a copy so the Maps are distinct
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/invertase/react-native-firebase/9K96QYoio9tpV87EPmtzSLWUpa2U |
Codecov Report
@@ Coverage Diff @@
## master #5236 +/- ##
=======================================
Coverage 88.86% 88.86%
=======================================
Files 109 109
Lines 3743 3743
Branches 360 360
=======================================
Hits 3326 3326
Misses 370 370
Partials 47 47 |
… 0.61.0 #5236 accidentally required a symbol defined here facebook/react-native@ac7ec46 which was not released until react-native 0.61
this should be the inline equivalent of the rn61 symbol I added in #5236 - accidentally breaking react-native 0.60 compatibility
this should be the inline equivalent of the rn61 symbol I added in #5236 - accidentally breaking react-native 0.60 compatibility
this should be the inline equivalent of the rn61 symbol I added in #5236 - accidentally breaking react-native 0.60 compatibility
this should be the inline equivalent of the rn61 symbol I added in #5236 - accidentally breaking react-native 0.60 compatibility
this should be the inline equivalent of the rn61 symbol I added in #5236 - accidentally breaking react-native 0.60 compatibility
this should be the inline equivalent of the rn61 symbol I added in invertase#5236 - accidentally breaking react-native 0.60 compatibility
Description
WritableNativeMap has a check to see if it is consumed or not when it is used,
to prevent resolving a Promise in native code then attempting to modify it.
We may use the same WritableNativeMap object twice though when handling deferred
initial notifications. Crash repair is to store a copy so the Maps are distinct
Related issues
Fixes #5231
Release Summary
conventional commit
Checklist
Android
iOS
e2e
tests added or updated inpackages/\*\*/e2e
jest
tests added or updated inpackages/\*\*/__tests__
Test Plan
Hard to test - will rely on @xxsnakerxx for reports on whether it happens or not, they appear to have a customer with a reproduction case
Think
react-native-firebase
is great? Please consider supporting the project with any of the below:React Native Firebase
andInvertase
on Twitter