Closed geniuscd closed 6 years ago
I don't see how the file://
prefix affects #10 , it is just a return value after all. Can you revert that?
on android, you have to add the 'file://' to the path or you won't be able to locate it. so indeed when the file is saved in the cache, and we want to read it, we have to use the file:// otherwise, the error in #10 will appear.
You should add the file://
prefix in your own js code.
Why inserting Platform.OS just to do the following. on android every time you need to read a file you should use the file:// prefix. so why not add it to the android.java file and in the .JS code we don't have to add it every time. That's my thought.
Not always. For example I use react-native-fetch-blob and I feed the path as-is. So far I haven't needed a path that is prefixed with file://
And if you really need a reason: this is a breaking change for people who have prepended the prefix manually. I have not planned to break the library at the moment. I appreciate your contribution, but please remove the prefix.
Thanks
FIX: adding .reset() method before release on android only. prepanding the 'file://' to the path return from android only