We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cc624b9 commit 92e330aCopy full SHA for 92e330a
.ruby-version
@@ -0,0 +1 @@
1
+3.1.4
lib/ransack/search.rb
@@ -102,14 +102,14 @@ def new_sort(opts = {})
102
def method_missing(method_id, *args)
103
method_name = method_id.to_s
104
getter_name = method_name.sub(/=$/, ''.freeze)
105
- if base.attribute_method?(getter_name)
106
- base.send(method_id, *args)
107
- elsif @context.ransackable_scope?(getter_name, @context.object)
+ if @context.ransackable_scope?(getter_name, @context.object)
108
if method_name =~ /=$/
109
add_scope getter_name, args
110
else
111
@scope_args[method_name]
112
end
+ elsif base.attribute_method?(getter_name)
+ base.send(method_id, *args)
113
114
super
115
0 commit comments