MCPcopy
hub / github.com/FiloSottile/age / expectStanzaWithBody

Function expectStanzaWithBody

plugin/plugin.go:590–598  ·  view source on GitHub ↗
(s *format.Stanza, wantArgs int)

Source from the content-addressed store, hash-verified

588}
589
590func expectStanzaWithBody(s *format.Stanza, wantArgs int) error {
591 if len(s.Args) != wantArgs {
592 return fmt.Errorf("%s stanza has %d arguments, want %d", s.Type, len(s.Args), wantArgs)
593 }
594 if len(s.Body) == 0 {
595 return fmt.Errorf("%s stanza has 0 bytes of body, want >0", s.Type)
596 }
597 return nil
598}
599
600func (p *Plugin) recipientError(idx int, err error) int {
601 if err := p.writeError([]string{"recipient", fmt.Sprint(idx)}, err); err != nil {

Callers 2

RecipientV1Method · 0.85
RequestValueMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…