From: wmorgan Date: Sat, 7 Jul 2007 14:30:13 +0000 (+0000) Subject: make conjunctive queries the default, and stop ignoring stopwords X-Git-Url: https://git.cworth.org/git?a=commitdiff_plain;h=cb2a359d3d7ed9f55296c197327cfdb63ad767e5;p=sup make conjunctive queries the default, and stop ignoring stopwords git-svn-id: svn://rubyforge.org/var/svn/sup/trunk@479 5c8cc53c-5e98-4d25-b20a-d8db53a31250 --- diff --git a/lib/sup/index.rb b/lib/sup/index.rb index c436ffd..9ce4858 100644 --- a/lib/sup/index.rb +++ b/lib/sup/index.rb @@ -24,11 +24,11 @@ class Index @sources_dirty = false wsa = Ferret::Analysis::WhiteSpaceAnalyzer.new false - sa = Ferret::Analysis::StandardAnalyzer.new Ferret::Analysis::FULL_ENGLISH_STOP_WORDS, true + sa = Ferret::Analysis::StandardAnalyzer.new [], true @analyzer = Ferret::Analysis::PerFieldAnalyzer.new wsa @analyzer[:body] = sa @analyzer[:subject] = sa - @qparser ||= Ferret::QueryParser.new :default_field => :body, :analyzer => @analyzer + @qparser ||= Ferret::QueryParser.new :default_field => :body, :analyzer => @analyzer, :or_default => false @lock = Lockfile.new lockfile, :retries => 0, :max_age => nil self.class.i_am_the_instance self