From f0aee34d3f3faeeed864ae9d535a031763afcc68 Mon Sep 17 00:00:00 2001 From: Henri-Damien LAURENT Date: Fri, 18 Dec 2009 12:24:00 +0100 Subject: [PATCH] followup : auto_truncation 3287252c0 truncated words bore a double * which would create an error Conflicts solved : C4/Search.pm --- C4/Search.pm | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/C4/Search.pm b/C4/Search.pm index bdf1434b1b..47ac7a36d0 100644 --- a/C4/Search.pm +++ b/C4/Search.pm @@ -1139,7 +1139,13 @@ sub buildQuery { } if ($auto_truncation){ - $operand=~join(" ",map{ "$_*" }split (/\s+/,$operand)); + unless ( $index =~ /(st-|phr|ext)/ ) { + #FIXME only valid with LTR scripts + $operand=join(" ",map{ + (index($_,"*")>0?"$_":"$_*") + }split (/\s+/,$operand)); + warn $operand if $DEBUG; + } } # Detect Truncation -- 2.39.5