code: func RedirectHTTP(w http.ResponseWriter, r *http.Request) {
  	if r.TLS != nil || r.Host == "" {
  		http.Error(w, "not found", 404)
  	}
  
  	u := r.URL
  	u.Host = r.Host
  	u.Scheme = "https"
  	http.Redirect(w, r, u.String(), 302)
  }
docs: // RedirectHTTP is an HTTP handler (suitable for use with http.HandleFunc)
  // that responds to all requests by redirecting to the same URL served over HTTPS.
  // It should only be invoked for requests received over HTTP.