Crashes at first request using fetch() polyfill #288
Comments
Does anyone understand the error? |
@GeoffreyPlitt , is there a code snippet about how you use the fetch replacement? It'd be helpful to replicate the error. |
Sure. I define/override "fetch" as documented:
Then I upload something with this kind of logic:
|
@GeoffreyPlitt , I've tried to use your code to upload a file to Cloudinary, but I got a different error from the server. {"error":{"message":"Invalid URL for upload"}} I'll keep look into this issue (might take quite a long time) before I find solution I suggest you can try use |
Remove extra semi-column when Fetch Replacement parsing FormData #288 This is non-standard behavior which may cause server side incompatible.
I have noticed the form data generated by The fix already committed to branch |
I'm using RN=0.42 and the latest version of this lib, testing on iOS simulator.
We're using the "fetch polyfill" approach mentioned at https://github.com/wkh237/react-native-fetch-blob/wiki/Fetch-API#fetch-replacement.
As soon as we call fetch() with a HTTPs url, it crashes. From the logs, it appears to be a native exception, and I'm not quite sure what's wrong, but I imagine the authors of this lib will know.
Logs:
The text was updated successfully, but these errors were encountered: