diff --git a/git-send-email.perl b/git-send-email.perl index 228400b3e9..09ecad830f 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -774,9 +774,9 @@ if (!$force) { } } -($sender) = expand_aliases($sender) if defined $sender; - -if (!defined $sender) { +if (defined $sender) { + ($sender) = expand_aliases($sender); +} else { $sender = $repoauthor || $repocommitter || ''; }