We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8c4de97 commit 0d49875Copy full SHA for 0d49875
package/native-package/src/index.js
@@ -154,7 +154,7 @@ registerNativeHandlers({
154
},
155
saveFile: async ({ fileName, fromUrl }) => {
156
try {
157
- const path = RNFS.DocumentDirectoryPath + '/' + fileName;
+ const path = RNFS.CachesDirectoryPath + '/' + encodeURIComponent(fileName);
158
await RNFS.downloadFile({ fromUrl, toFile: path }).promise;
159
return 'file://' + path;
160
} catch (error) {
0 commit comments