title: React-Native Network Request Failed only in HTTPS
body: <p>This code works perfectly fine for a few months:</p>
  
  <pre><code>try {
      return await fetch(url + '/api/v2/login?'+param).then((response) =&gt; {
          return response.json()
      });
  }
  catch (err) {
      console.log(err.message)
  }
  </code></pre>
  
  <p>But last week, react-native throws an error "Network Request Failed".
  I'm sure that our API is working because I already have tested it in a few online API Tester.</p>
  
  <p>And when I didn't force the HTTPS, and just the HTTP, it works.</p>
  
  <p>And our current react version is: 0.41</p>
  
  <p>Here is the error:</p>
  
  <pre><code>at XMLHttpRequest.xhr.onerror (fetch.js:441)
  at XMLHttpRequest.dispatchEvent (event-target.js:172)
  at XMLHttpRequest.setReadyState (XMLHttpRequest.js:546)
  at XMLHttpRequest.__didCompleteResponse (XMLHttpRequest.js:381)
  at XMLHttpRequest.js:485
  at RCTDeviceEventEmitter.emit (EventEmitter.js:181)
  at MessageQueue.__callFunction (MessageQueue.js:266)
  at MessageQueue.js:103
  at MessageQueue.__guard (MessageQueue.js:231)
  at MessageQueue.callFunctionReturnFlushedQueue (MessageQueue.js:102)
  </code></pre>