Fix Share dialog not resolving promise when dismissed on iOS#26842
Fix Share dialog not resolving promise when dismissed on iOS#26842v-fernandez wants to merge 1 commit intofacebook:masterfrom
Conversation
|
So it looks like this is because of my PR (#26429). I added this check because we need to have some sort of guard against the success callback being called multiple times. Is there a way we can know that the ActionSheet was closed so we can do |
|
@v-fernandez so I think we can change the check to: It looks like in Here's when they close the reminders modal: This should fix the current issue without reintroducing the crash. |
|
@tomtargosz makes sense. I'll update the PR with this. Thanks for the help! |
362d2dc to
bae030b
Compare
facebook-github-bot
left a comment
There was a problem hiding this comment.
@cpojer is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
|
This pull request was successfully merged by @v-fernandez in 7468a6c. When will my fix make it into a release? | Upcoming Releases |
|
When is this PR going to be picked? |
https://github.com/facebook/react-native/releases/tag/v0.62.0-rc.0 |



Summary
On iOS the promised returned by
Share.share(content, options)isn't resolved if the user dismisses the dialog by either pressing "Cancel" or pressing outside the shared dialog. This PR fixes this issue.This fixes #26809.
Changelog
[iOS] [Fixed] - Fix promised returned by
Share.share(content, options)not resolving if share dialog dismissedTest Plan