title: javascript fetch automatically changes http with https
body: <p>I am making a request with fetch at the client side with this code:</p>
  <pre><code>    var request = new Request(`http://ip:8080/click?url=${value}`, {
          method: 'GET',
          headers: new Headers({
              &quot;Content-Type&quot;: &quot;application/json&quot;
          }),
      });
      fetch(request)
  </code></pre>
  <p>but when the browser makes the request, it automatically changes the URL with https protocol:</p>
  <blockquote>
  <p><strong>https://ip:8080/click?url=${value}</strong></p>
  </blockquote>
  <p>Note: the webpage has SSL encryption</p>
  <blockquote>
  <p>Subsequently, I get this error on the webpage console: <strong>Failed to
  load resource: net::ERR_CONNECTION_CLOSED</strong></p>
  </blockquote>