MCPcopy Create free account
hub / github.com/compozy/agh / taskSecretValueContainsSecret

Function taskSecretValueContainsSecret

internal/task/block_service.go:554–568  ·  view source on GitHub ↗
(value any)

Source from the content-addressed store, hash-verified

552}
553
554func taskSecretValueContainsSecret(value any) bool {
555 switch typed := value.(type) {
556 case map[string]any:
557 for key, nested := range typed {
558 if taskSecretKeyCarriesSecret(key) || taskSecretValueContainsSecret(nested) {
559 return true
560 }
561 }
562 case []any:
563 return slices.ContainsFunc(typed, taskSecretValueContainsSecret)
564 case string:
565 return redactTaskSecretText(typed) != typed
566 }
567 return false
568}
569
570func redactTaskSecretValue(value any) any {
571 switch typed := value.(type) {

Callers 1

rejectTaskSecretJSONFunction · 0.85

Calls 2

redactTaskSecretTextFunction · 0.85

Tested by

no test coverage detected