Changeset 14559

Show
Ignore:
Timestamp:
24.09.2007 09:03:12 (12 years ago)
Author:
mdewsnip
Message:

Fixed a bug where "OR" searches were always performed because == was used instead of .equals() for a string comparison.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • indexers/trunk/lucene-gs/src/org/greenstone/LuceneWrapper/GS2LuceneQuery.java

    r13909 r14559  
    211211    public void setDefaultConjunctionOperator(String default_conjunction_operator) { 
    212212    this.default_conjunction_operator = default_conjunction_operator.toUpperCase(); 
    213     if (default_conjunction_operator == "AND") { 
     213    if (default_conjunction_operator.equals("AND")) { 
    214214        query_parser.setDefaultOperator(query_parser.AND_OPERATOR); 
    215215        query_parser_no_stop_words.setDefaultOperator(query_parser.AND_OPERATOR);