diff options
author | Remi Lespinet <remi.lespinet@ensimag.grenoble-inp.fr> | 2015-06-30 14:16:47 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2015-06-30 11:34:35 -0700 |
commit | c46e27aa774eae2ac58f1763afe00108f3a1e5d3 (patch) | |
tree | 3dbda4b16d65dd1a6053baf6566fbe48909992b7 /git-send-email.perl | |
parent | 193d7160111ebf5b898f53240c33c1e4101d9598 (diff) | |
download | git-c46e27aa774eae2ac58f1763afe00108f3a1e5d3.tar.gz |
send-email: minor code refactoring
Group expressions in a single if statement. This avoid checking
multiple time if the variable $sender is defined.
Signed-off-by: Remi Lespinet <remi.lespinet@ensimag.grenoble-inp.fr>
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-send-email.perl')
-rwxr-xr-x | git-send-email.perl | 6 |
1 files changed, 3 insertions, 3 deletions
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 || ''; } |