Bug 12478: Remove empty limit parameter
If no limit are passed, the url will contain '&limit=' anyway. It is not necessary and can be avoided easily Test plan: 1/ Search for a term in your catalogue 2/ Hover over a link in the facet area 3/ The link is cgi-bin/koha/opac-search.pl?idx=kw&q=your_term&limit=&limit=[...] With this patch, the empty limit parameter does not appear. Signed-off-by: Nick Clemens <nick@bywatersolutions.com> Signed-off-by: Jesse Weaver <jweaver@bywatersolutions.com> Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io> Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> Signed-off-by: Brendan Gallagher <brendan@bywatersolutions.com>
This commit is contained in:
parent
246f2dddaf
commit
ce5bc33ef3
|
|
@ -223,8 +223,9 @@ sub build_query_compat {
|
|||
my $simple_query = $operands->[0] if @$operands == 1;
|
||||
my $query_desc = $simple_query;
|
||||
my $limit = $self->_join_queries( $self->_convert_index_strings(@$limits));
|
||||
my $limit_cgi =
|
||||
'&limit=' . join( '&limit=', map { uri_escape_utf8($_) } @$orig_limits );
|
||||
my $limit_cgi = ( $orig_limits and @$orig_limits )
|
||||
? '&limit=' . join( '&limit=', map { uri_escape_utf8($_) } @$orig_limits )
|
||||
: '';
|
||||
my $limit_desc = "$limit" if $limit;
|
||||
return (
|
||||
undef, $query, $simple_query, $query_cgi, $query_desc,
|
||||
|
|
|
|||
Loading…
Reference in New Issue