MCPcopy Index your code
hub / github.com/cloudfoundry/cli / normalizeURLPath

Function normalizeURLPath

actor/pluginaction/plugin_repository.go:67–76  ·  view source on GitHub ↗
(rawURL string)

Source from the content-addressed store, hash-verified

65}
66
67func normalizeURLPath(rawURL string) (string, error) {
68 prefix := ""
69 if !strings.Contains(rawURL, "://") {
70 prefix = "https://"
71 }
72
73 normalizedURL := fmt.Sprintf("%s%s", prefix, rawURL)
74
75 return strings.TrimSuffix(normalizedURL, "/"), nil
76}

Callers 1

AddPluginRepositoryMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected