diff options
Diffstat (limited to 'git-send-email.perl')
-rwxr-xr-x | git-send-email.perl | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/git-send-email.perl b/git-send-email.perl index 91607c5878..6885dfa1b9 100755 --- a/git-send-email.perl +++ b/git-send-email.perl @@ -337,8 +337,16 @@ sub read_config { } foreach my $setting (keys %config_path_settings) { - my $target = $config_path_settings{$setting}->[0]; - $$target = Git::config_path(@repo, "$prefix.$setting") unless (defined $$target); + my $target = $config_path_settings{$setting}; + if (ref($target) eq "ARRAY") { + unless (@$target) { + my @values = Git::config_path(@repo, "$prefix.$setting"); + @$target = @values if (@values && defined $values[0]); + } + } + else { + $$target = Git::config_path(@repo, "$prefix.$setting") unless (defined $$target); + } } foreach my $setting (keys %config_settings) { |