removing sanatized operand, we can now handle non-sanatized operands
authorJoshua Ferraro <jmf@liblime.com>
Wed, 21 Nov 2007 23:57:17 +0000 (17:57 -0600)
committerJoshua Ferraro <jmf@liblime.com>
Thu, 22 Nov 2007 00:08:40 +0000 (18:08 -0600)
Signed-off-by: Chris Cormack <crc@liblime.com>
Signed-off-by: Joshua Ferraro <jmf@liblime.com>
C4/Search.pm

index b84a528..5f15f96 100644 (file)
@@ -722,10 +722,6 @@ sub buildQuery {
 
                                $weight_fields = 0 if $operands[$i] =~ /(:|=)/;
                 my $operand = $operands[$i];
-
-                               my $sanatized_operand = $operands[$i];
-                               $sanatized_operand =~ s/://g;
-
                 my $index   = $indexes[$i];
 
                 # if there's no index, don't use one, it will throw a CCL error
@@ -794,7 +790,7 @@ sub buildQuery {
                         $query .= " $operand";
                                                $query_cgi .="&op=$operators[$i-1]";
                                                $query_cgi .="&idx=$index" if $index;
-                                               $query_cgi .="&q=$sanatized_operand" if $sanatized_operand;
+                                               $query_cgi .="&q=$operands[$i]" if $operands[$i];
                                                $query_search_desc .=" $operators[$i-1] $index_plus $operands[$i]";
                     }
 
@@ -804,7 +800,7 @@ sub buildQuery {
                         $query .= "$index_plus " unless $indexes_set;
                         $query .= "$operand";
                                                $query_cgi .="&op=and&idx=$index" if $index;
-                                               $query_cgi .="&q=$sanatized_operand" if $sanatized_operand;
+                                               $query_cgi .="&q=$operands[$i]" if $operands[$i];
                         $query_search_desc .= " and $index_plus $operands[$i]";
                     }
                 }
@@ -815,7 +811,7 @@ sub buildQuery {
                                        $query .= $operand;
                                        $query_search_desc .= " $index_plus $operands[$i]";
                                        $query_cgi.="&idx=$index" if $index;
-                                       $query_cgi.="&q=$sanatized_operand" if $sanatized_operand;
+                                       $query_cgi.="&q=$operands[$i]" if $operands[$i];
 
                     $previous_operand = 1;
                 }