I'm having trouble getting ThinkingSphinx to recognize my conditions.
My Discussion model includes the following code:
define_index do
indexes [subject, body], :as => :text
indexes replies.body, :as => :reply_text
set_property :delta => true
end
And as expected this search
Discussion.search "handy"
returns any discussion with the word "handy" in its subject, body, or the body of one of its replies.
Now I'm implementing a "deleting posts" feature, and I want to show only discussions where the field called :disabled == false.
Unfortunately, this search:
Discussion.search "handy", :conditions => { :disabled => false }
always returns an empty array, no matter what.
Why?