MCPcopy Create free account
hub / github.com/openclaw/gogcli / buildForwardSubject

Function buildForwardSubject

internal/cmd/gmail_forward.go:152–159  ·  view source on GitHub ↗

buildForwardSubject prepends "Fwd: " to the subject, avoiding duplication.

(subject string)

Source from the content-addressed store, hash-verified

150
151// buildForwardSubject prepends "Fwd: " to the subject, avoiding duplication.
152func buildForwardSubject(subject string) string {
153 subject = strings.TrimSpace(subject)
154 if subject == "" {
155 return "Fwd: (no subject)"
156 }
157 stripped := stripForwardPrefix(subject)
158 return "Fwd: " + stripped
159}
160
161// stripForwardPrefix removes existing Fwd:/Fw:/FWD: prefixes from a subject.
162func stripForwardPrefix(subject string) string {

Callers 2

TestBuildForwardSubjectFunction · 0.85
RunMethod · 0.85

Calls 1

stripForwardPrefixFunction · 0.85

Tested by 1

TestBuildForwardSubjectFunction · 0.68