Re: [PATCH 1/3] gitweb: Move check-ref-format code into separate function

2013-12-03 Thread Junio C Hamano
Krzesimir Nowak krzesi...@endocode.com writes: This check will be used in more than one place later. Signed-off-by: Krzesimir Nowak krzesi...@endocode.com Reviewed-by: Junio C Hamano gits...@pobox.com Reviewed-by: Jakub Narębski jna...@gmail.com Reviewed-by: Eric Sunshine

Re: [PATCH 1/3] gitweb: Move check-ref-format code into separate function

2013-12-03 Thread Jakub Narębski
On Tue, Dec 3, 2013 at 8:02 PM, Junio C Hamano gits...@pobox.com wrote: Krzesimir Nowak krzesi...@endocode.com writes: +sub check_ref_format { + my $input = shift || return undef; + + # restrictions on ref name according to git-check-ref-format + if ($input =~

Re: [PATCH 1/3] gitweb: Move check-ref-format code into separate function

2013-12-03 Thread Junio C Hamano
Jakub Narębski jna...@gmail.com writes: Stricly speaking pure refactoring (no functional change, e.g. no assign to $input) would be check_ref_format($input) or return undef;, or even return check_ref_format($input); if we keep check_ref_format() passthru on valid refname. Exactly. -- To