Thread (1 message) 1 message, 1 author, 2016-06-15

Re: [PATCH] gitweb: Make config_to_multi return [] instead of [undef]

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:43:57

Jakub Narebski [off-list ref] writes:
Petr Baudis [off-list ref] writes:
quoted
This is important for the list of clone urls, where if there are
no per-repository clone URL configured, the default base URLs
are never used for URL construction with this patch.
Thanks.
 
quoted
@@ -1512,7 +1512,7 @@ sub config_to_int {
 sub config_to_multi {
 	my $val = shift;
 
-	return ref($val) ? $val : [ $val ];
+	return ref($val) ? $val : $val ? [ $val ] : [];
 }
Shouldn't it be

  +	return ref($val) ? $val : defined($val) ? [ $val ] : [];
I think so.  Pasky?
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help