MCPcopy
hub / github.com/larksuite/cli / WriteAlertWarning

Function WriteAlertWarning

internal/output/emit.go:53–59  ·  view source on GitHub ↗

WriteAlertWarning writes a human-readable content-safety warning to w. Used by non-JSON output paths (pretty, table, csv) in warn mode.

(w io.Writer, alert *extcs.Alert)

Source from the content-addressed store, hash-verified

51// WriteAlertWarning writes a human-readable content-safety warning to w.
52// Used by non-JSON output paths (pretty, table, csv) in warn mode.
53func WriteAlertWarning(w io.Writer, alert *extcs.Alert) {
54 if alert == nil {
55 return
56 }
57 fmt.Fprintf(w, "warning: content safety alert from %s (rules: %s)\n",
58 alert.Provider, strings.Join(alert.MatchedRules, ", "))
59}

Callers 7

HandleResponseFunction · 0.92
servicePaginateFunction · 0.92
apiPaginateFunction · 0.92
outFormatMethod · 0.92
WriteSuccessEnvelopeFunction · 0.85
TestWriteAlertWarningFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestWriteAlertWarningFunction · 0.68