MCPcopy Create free account
hub / github.com/cli/cli / ImmutableSafeURL

Struct ImmutableSafeURL

internal/safeurl/safeurl.go:111–113  ·  view source on GitHub ↗

ImmutableSafeURL is a SafeURL that renders a fixed URL string verbatim. It exists so that a URL which was not built from percent-encoded components, such as a full URL returned by the server (a pagination "next" link, an asset download URL, and the like), can still flow through the SafeURL typed cod

Source from the content-addressed store, hash-verified

109// value is rendered as given without any encoding, it is only safe to wrap a URL that
110// was created from trusted components or received from a trusted source.
111type ImmutableSafeURL struct {
112 url string
113}
114
115// NewImmutableSafeURL returns an ImmutableSafeURL that renders url verbatim. Only pass
116// a URL you built yourself from trusted components or received from a trusted source,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected