MCPcopy Index your code
hub / github.com/cloudquery/cloudquery / hasPlatformDestination

Function hasPlatformDestination

cli/internal/platform/inject.go:373–380  ·  view source on GitHub ↗

hasPlatformDestination reports whether the spec already declares a `platform` destination (a user-provided one the CLI must not overwrite).

(destinations []*specs.Destination)

Source from the content-addressed store, hash-verified

371// hasPlatformDestination reports whether the spec already declares a `platform`
372// destination (a user-provided one the CLI must not overwrite).
373func hasPlatformDestination(destinations []*specs.Destination) bool {
374 for _, d := range destinations {
375 if d.Name == destinationName {
376 return true
377 }
378 }
379 return false
380}
381
382// injectPlatformDestination appends the reserved `platform` destination carrying
383// the cqpd_ token. The caller guarantees a source already targets it (the opt-in)

Callers 1

MaybeInjectDestinationFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected