joltup / rn-fetch-blob

A project committed to making file access and data transfer easier, efficient for React Native developers.
MIT License
2.81k stars 773 forks source link

(Android) Fix multi-byte UTF-8 issue : Translating the non english language data properly #479

Closed sadafk831 closed 4 years ago

sadafk831 commented 4 years ago

Fixes #297

Purpose of the PR

We are having this issue for all our Arabic data received from the server as that data gets converted to some gibberish data after we use RNFetchBlob fetch as

RNFetchBlob.fetch(method, url, { 'RNFB-Response' : 'utf8',  ...headers }, body )

The proposed changes fix the issue, and again we can see the Arabic content as supposed to be.

How did I tested

sadafk831 commented 4 years ago

@Traviskn would be great if I can get a quick review on this as this looks like a road blocker for us.

Traviskn commented 4 years ago

Thank you for this PR, apologies for the slow review

mjmasn commented 4 years ago

Thanks for taking this one on @sadafk831 :tada: