(ctx context.Context, rcptTo string)
| 97 | } |
| 98 | |
| 99 | func (gs groupState) RewriteRcpt(ctx context.Context, rcptTo string) ([]string, error) { |
| 100 | var err error |
| 101 | var result = []string{rcptTo} |
| 102 | for _, state := range gs.states { |
| 103 | var intermediateResult = []string{} |
| 104 | for _, partResult := range result { |
| 105 | var partResult_multi []string |
| 106 | partResult_multi, err = state.RewriteRcpt(ctx, partResult) |
| 107 | if err != nil { |
| 108 | return []string{""}, err |
| 109 | } |
| 110 | intermediateResult = append(intermediateResult, partResult_multi...) |
| 111 | } |
| 112 | result = intermediateResult |
| 113 | } |
| 114 | return result, nil |
| 115 | } |
| 116 | |
| 117 | func (gs groupState) RewriteBody(ctx context.Context, h *textproto.Header, body buffer.Buffer) error { |
| 118 | for _, state := range gs.states { |
nothing calls this directly
no test coverage detected