header: remove trailing colon in header field

With this commit trailing colons in the :header command's field are
removed to prevent double-colon-headers from being sent.

Signed-off-by: Moritz Poldrack <git@moritz.sh>
Acked-by: Robin Jarry <robin@jarry.cc>
This commit is contained in:
Moritz Poldrack 2022-04-05 23:49:13 +02:00 committed by Robin Jarry
parent 7fe7fe4ea8
commit 3c08b8e6a9
1 changed files with 2 additions and 0 deletions

View File

@ -56,6 +56,8 @@ func (Header) Execute(aerc *widgets.Aerc, args []string) error {
composer, _ := aerc.SelectedTab().(*widgets.Composer)
args[optind] = strings.TrimRight(args[optind], ":")
value := strings.Join(args[optind+1:], " ")
if !force {