grep by non-zero length

parent 987d5930
......@@ -350,7 +350,7 @@ sub get_best_url {
sub assemble_url {
my ($package, $uri, @segments) = @_;
$uri->path_segments(grep { defined } $uri->path_segments, @segments);
$uri->path_segments(grep { length > 0 } $uri->path_segments, @segments);
return $uri;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment