Skip to content
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: read file failed on android 10 and above without requestLegacyExternalStorage #1

Merged
merged 3 commits into from
Nov 26, 2020

Conversation

ewfian
Copy link

@ewfian ewfian commented Nov 26, 2020

Due to Api 29+ Behavior changes, The scoped storage should fixed.
The pull request aims to fix read file failed without announces android:requestLegacyExternalStorage flag.
When Api level gte 29. The behavior fallback to copy file to temp dir and return temp file back.

References:
https://github.com/ivpusic/react-native-image-crop-picker/blob/798ac61cf94c393bea833f1b583bbfba7a09c6ea/android/src/main/java/com/reactnative/ivpusic/imagepicker/RealPathUtil.java#L138
https://github.com/hiddentao/cordova-plugin-filepath/blob/7b8847e0b182c2a1f427a31f3b04f40e11842144/src/android/FilePath.java#L420

Related: apache#585, apache#573, apache#531, apache#548, apache#554, apache#558, apache#563

@ewfian ewfian merged commit 60928f5 into master Nov 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant