mirror of
https://github.com/git/git
synced 2024-08-24 18:26:02 +00:00
gitweb: remove unused guess_file_syntax() parameter
Signed-off-by: Ian Kelling <ian@iankelling.org> Acked-by: Jakub Narębski <jnareb@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
parent
6fe1b1407e
commit
c151aa3b58
|
@ -3913,7 +3913,7 @@ sub blob_contenttype {
|
|||
# guess file syntax for syntax highlighting; return undef if no highlighting
|
||||
# the name of syntax can (in the future) depend on syntax highlighter used
|
||||
sub guess_file_syntax {
|
||||
my ($highlight, $mimetype, $file_name) = @_;
|
||||
my ($highlight, $file_name) = @_;
|
||||
return undef unless ($highlight && defined $file_name);
|
||||
my $basename = basename($file_name, '.in');
|
||||
return $highlight_basename{$basename}
|
||||
|
@ -7062,7 +7062,7 @@ sub git_blob {
|
|||
$have_blame &&= ($mimetype =~ m!^text/!);
|
||||
|
||||
my $highlight = gitweb_check_feature('highlight');
|
||||
my $syntax = guess_file_syntax($highlight, $mimetype, $file_name);
|
||||
my $syntax = guess_file_syntax($highlight, $file_name);
|
||||
$fd = run_highlighter($fd, $highlight, $syntax)
|
||||
if $syntax;
|
||||
|
||||
|
|
Loading…
Reference in a new issue