lib/searchlogic/named_scopes/or_conditions.rb in searchlogic-2.4.12 vs lib/searchlogic/named_scopes/or_conditions.rb in searchlogic-2.4.13
- old
+ new
@@ -119,10 +119,10 @@
def create_or_condition(scopes, args)
scopes_options = scopes.collect { |scope, *args| send(scope, *args).proxy_options }
# We're using first scope to determine column's type
scope = named_scope_options(scopes.first)
- column_type = scope.respond_to?(:searchlogic_arg_type) ? scope.searchlogic_arg_type : :string
+ column_type = scope.respond_to?(:searchlogic_options) ? scope.searchlogic_options[:type] : :string
named_scope scopes.join("_or_"), searchlogic_lambda(column_type) { |*args|
merge_scopes_with_or(scopes.collect { |scope| clone.send(scope, *args) })
}
end