Merge remote branch 'kc/new/bug_5651' into kcmaster

This commit is contained in:
Chris Cormack 2011-04-06 15:34:56 +12:00
commit b1daec9fa3

View file

@ -1122,10 +1122,12 @@ sub buildQuery {
my $indexes_set;
# If the user is sophisticated enough to specify an index, turn off field weighting, stemming, and stopword handling
if ( $operands[$i] =~ /(:|=)/ || $scan ) {
if ( $operands[$i] =~ /\w(:|=)/ || $scan ) {
$weight_fields = 0;
$stemming = 0;
$remove_stopwords = 0;
} else {
$operands[$i] =~ s/\?/{?}/g; # need to escape question marks
}
my $operand = $operands[$i];
my $index = $indexes[$i];