github.com/DaAlbrecht/cf-cli@v0.0.0-20231128151943-1fe19bb400b9/util/url.go (about)

     1  package util
     2  
     3  import "strings"
     4  
     5  func IsHTTPScheme(path string) bool {
     6  	return strings.HasPrefix(path, "http://") || strings.HasPrefix(path, "https://")
     7  }
     8  
     9  func IsUnsupportedURLScheme(path string) bool {
    10  	return strings.Contains(path, "://") && !IsHTTPScheme(path)
    11  }