Skip to content

Commit

Permalink
Release v1.6.3
Browse files Browse the repository at this point in the history
  • Loading branch information
binarylogic committed Feb 2, 2009
1 parent 3ee7496 commit c0e02bb
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/searchlogic/conditions/base.rb
Expand Up @@ -227,7 +227,7 @@ def join_object_with_any?(object)
if condition?(object) || group?(object)
object.explicit_any?
elsif association?(object)
join_object_with_any?(object.send(:objects).first)
object.send(:join_object_with_any?, object.send(:objects).first)
end
end

Expand Down
2 changes: 1 addition & 1 deletion lib/searchlogic/version.rb
Expand Up @@ -67,7 +67,7 @@ def to_a

MAJOR = 1
MINOR = 6
TINY = 2
TINY = 3

# The current version as a Version instance
CURRENT = new(MAJOR, MINOR, TINY)
Expand Down
7 changes: 7 additions & 0 deletions test/conditions_tests/base_test.rb
Expand Up @@ -174,5 +174,12 @@ def test_reset
conditions.reset!
assert_equal [], conditions.send(:objects)
end

def test_join_with_or_with_association
conditions = Searchlogic::Cache::AccountConditions.new
conditions.name_ends_with = "Binary"
conditions.users.or_first_name_like = "whatever"
assert_equal ["\"accounts\".\"name\" LIKE ? OR \"users\".\"first_name\" LIKE ?", "%Binary", "%whatever%"], conditions.sanitize
end
end
end

0 comments on commit c0e02bb

Please sign in to comment.