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
I did same change on my local library and tested on our APP, and that worked on actual device and emulator both.
I read the related issues, and saw the reverted PR #353 as that fix had the missing if/else condition which made the base64 crash, I added that check also in this PR.
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 asThe proposed changes fix the issue, and again we can see the Arabic content as supposed to be.
How did I tested
if/else
condition which made the base64 crash, I added that check also in this PR.