From 9efdfa1ba2360bfec2b2d88a6a6388b2dfe77a36 Mon Sep 17 00:00:00 2001 From: Magnus Enger Date: Thu, 16 Jun 2011 13:51:58 +0200 Subject: [PATCH] Bug 6510 - [REVISED] Sort by in intranet search alters search and number of hits This patch uses .*? instead of .* To test: - In advanced search in the intranet choose Author as the search index - Do a search for an author, check the number of hits - Choose another value than the default from Sort by - Check that the number of hits is the same as for the original search, once the hits have been re-ordered Signed-off-by: MJ Ray Signed-off-by: Chris Cormack --- catalogue/search.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/catalogue/search.pl b/catalogue/search.pl index a41b18adc3..8899d59293 100755 --- a/catalogue/search.pl +++ b/catalogue/search.pl @@ -471,7 +471,7 @@ my $scan_index_to_use; for my $this_cgi ( split('&',$query_cgi) ) { next unless $this_cgi; - $this_cgi =~ m/(.?)=(.*)/; + $this_cgi =~ m/(.*?)=(.*)/; my $input_name = $1; my $input_value = $2; push @query_inputs, { input_name => $input_name, input_value => $input_value }; -- 2.39.5