code: func CheckURL(s string) (string, error) {
  	u, err := url.Parse(s)
  	if err != nil {
  		return "", err
  	}
  	if u.Scheme == "" {
  		s = "https://" + s
  		u.Scheme = "https"
  	}
  	if u.Scheme != "https" && u.Scheme != "http" {
  		return "", errors.New("Only http:// or https:// scheme is accepted.")
  	}
  	if u.Scheme != "https" && hostRequiresSSL(u.Host) {
  		return "", errors.New("only https:// scheme is accepted for appspot hosts, it can be omitted")
  	}
  	if _, err = url.Parse(s); err != nil {
  		return "", err
  	}
  	return s, nil
  }
docs: // CheckURL ensures that the URL has a valid scheme, and that, if it is an
  // appspot server, that it uses HTTPS.
  //
  // If no protocol is specified, the protocol defaults to https://.