send-email: do not leave an empty CC: line if no cc is present.
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
parent
ca135e7acc
commit
f06a6a493a
@ -446,9 +446,12 @@ sub send_message
|
||||
my ($name, $addr) = ($from =~ /^(.*?)(\s+<.*)/);
|
||||
$from = "\"$name\"$addr";
|
||||
}
|
||||
my $ccline = "";
|
||||
if ($cc ne '') {
|
||||
$ccline = "\nCc: $cc";
|
||||
}
|
||||
my $header = "From: $from
|
||||
To: $to
|
||||
Cc: $cc
|
||||
To: $to${ccline}
|
||||
Subject: $subject
|
||||
Date: $date
|
||||
Message-Id: $message_id
|
||||
|
Loading…
Reference in New Issue
Block a user