r111030 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r111029‎ | r111030 | r111031 >
Date:12:46, 9 February 2012
Author:sbachenberg
Status:deferred (Comments)
Tags:
Comment:
Fixed: Bug with wildcard search + AND / OR notworking together
Modified paths:
  • /trunk/extensions/SolrStore/SolrTalker.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SolrStore/SolrTalker.php
@@ -142,6 +142,8 @@
143143 if ( strpos( $parts[1], '*' ) !== false ) {
144144 $parts[1] = strtolower( $parts[1] );
145145 }
 146+ //If we got an "AND" or an "OR" we have to write them upercase
 147+ $parts[1] = str_ireplace( 'and', 'AND', $parts[1] );
146148
147149 //If we have a solrField Match add a ':' (its the Lucene equivalent of '=' )
148150 if ( $solrField ) {

Comments

#Comment by Nikerabbit (talk | contribs)   12:53, 9 February 2012

Comment doesn't seem to match the code. What if we have "mandate"?

#Comment by VasilievVV (talk | contribs)   12:54, 9 February 2012

Besides, it's "uppercase", not "upercase".

#Comment by SBachenberg (talk | contribs)   08:58, 13 February 2012

Your are Absolutely right, i reverted this change in my Last commit. The real bug was a missing space between the "query string" and the "additional query string"

Status & tagging log