cgiurl: don't append "?" if there are no parameters
This means we can use cgiurl() instead of $config{cgiurl} if an absolute URL isn't desired.master
parent
8f64c69e08
commit
200c599dca
|
@ -1044,6 +1044,11 @@ sub cgiurl (@) {
|
|||
$cgiurl=$params{cgiurl};
|
||||
delete $params{cgiurl};
|
||||
}
|
||||
|
||||
unless (%params) {
|
||||
return $cgiurl;
|
||||
}
|
||||
|
||||
return $cgiurl."?".
|
||||
join("&", map $_."=".uri_escape_utf8($params{$_}), keys %params);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue