react-native
react-native copied to clipboard
[iOS] Remove invalidate observer instead of re-adding observer in DeviceInfo module
Summary:
Previous fix brings in https://github.com/facebook/react-native/pull/42396. Seems it's a mistake to re-add observer?
So let's remove it and also not invalidate method not be called twice.
Changelog:
[IOS] [FIXED] - Remove invalidate observer instead of re-adding observer in DeviceInfo module
Test Plan:
Fix for #42120 also works.
| Platform | Engine | Arch | Size (bytes) | Diff |
|---|---|---|---|---|
| android | hermes | arm64-v8a | 18,877,269 | -9 |
| android | hermes | armeabi-v7a | n/a | -- |
| android | hermes | x86 | n/a | -- |
| android | hermes | x86_64 | n/a | -- |
| android | jsc | arm64-v8a | 22,250,201 | +4 |
| android | jsc | armeabi-v7a | n/a | -- |
| android | jsc | x86 | n/a | -- |
| android | jsc | x86_64 | n/a | -- |
Base commit: 220588004b100717b0984bf33a48391746ecd3ff Branch: main
@cipolleschi has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.
This pull request was successfully merged by @zhongwuzw in 91279a822be949051866a694148e509c1308035b.
When will my fix make it into a release? | How to file a pick request?