mirror of
https://github.com/activerecord-hackery/ransack.git
synced 2022-11-09 13:47:45 -05:00
use respond_to?
instead of method_defined?
when aliasing search
Fixes #305
This commit is contained in:
parent
2ca4e4974a
commit
81fd2edd9f
1 changed files with 1 additions and 1 deletions
|
@ -4,7 +4,7 @@ module Ransack
|
|||
module Base
|
||||
|
||||
def self.extended(base)
|
||||
alias :search :ransack unless base.method_defined? :search
|
||||
alias :search :ransack unless base.respond_to? :search
|
||||
base.class_eval do
|
||||
class_attribute :_ransackers
|
||||
self._ransackers ||= {}
|
||||
|
|
Loading…
Reference in a new issue