func GetStatusOf(addr string) int {
	req, err := http.NewRequest(http.MethodOptions, addr, nil)
	if err != nil {
		log.Printf("Options request failed with: %s", err.Error())
		return http.StatusBadRequest // Assume I did something wrong, all other errors should be "successful"
	}
	res, err := http.DefaultClient.Do(req)
	if err != nil {
		log.Printf("Options request failed with: %s", err.Error())
		return http.StatusBadRequest // Assume I did something wrong, all other errors should be "successful"
	}
	res.Body.Close()
	return res.StatusCode
}
// GetStatusOf returns the status code of a head request to the root path of a remote.
GetStatusOf returns the status code of a head request to the root path of a remote.
// GetStatusOf returns the status code of a head request to the root path of a remote .
func GetStatusOf(addr string) int {
	req, err := http.NewRequest(http.MethodOptions, addr, nil)
	if err != nil {
		log.Printf("Options request failed with: %s", err.Error())
		return http.StatusBadRequest 
	}
	res, err := http.DefaultClient.Do(req)
	if err != nil {
		log.Printf("Options request failed with: %s", err.Error())
		return http.StatusBadRequest 
	}
	res.Body.Close()
	return res.StatusCode
}
func GetStatusOf ( addr string ) int { req , err := http . NewRequest ( http . MethodOptions , addr , nil ) if err != nil { log . Printf ( " " , err . Error ( ) ) return http . StatusBadRequest } res , err := http . DefaultClient . Do ( req ) if err != nil { log . Printf ( " " , err . Error ( ) ) return http . StatusBadRequest } res . Body . Close ( ) return res . StatusCode }
GetStatusOf returns the status code of a head request to the root path of a remote.
GetStatusOf returns the status code of a head request to the root path of a remote .
// Assume I did something wrong, all other errors should be "successful" // Assume I did something wrong, all other errors should be "successful"