/ plus_plugins Public
fix(share_plus): return correct share result on android #1301
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge.
shareFilesWithResultimplementations are broken. The returned
nullon successful share. This PR fixes this by using
FLAG_IMMUTABLE, as pointed out by @aakash-pamnani. This issue was not found when initially implementing the
shareWithResultmethods, as the
FLAG_IMMUTABLEwas only required by the highest API versions. Back then, a simple warning was emitted that strongly suggested using
FLAG_IMMUTABLE, which seemed to break nothing.
This PR now fixes the behavior and ensures that the
PendingIntentgiven out may not be abused by moving from an implicit internal
Intentto an explicit one. This also reduces mental complexity of the implementation.
I also added some more documentation throughout the android implementation.
As always, I provide share_plus_example as a pre-setup example project for this PR.
flutter analyze) does not report any problems on my PR.
Does your PR require plugin users to manually update their apps to accommodate your change?
!in the title as explained in Conventional Commits).