提交 5be49884 编写于 作者: E Ernie Miller 提交者: Pratik Naik

Prevent calling regexp on symbol in Ruby 1.9 in association_proxy

Signed-off-by: NPratik Naik <pratiknaik@gmail.com>
上级 743d77f4
......@@ -51,7 +51,7 @@ class AssociationProxy #:nodoc:
alias_method :proxy_respond_to?, :respond_to?
alias_method :proxy_extend, :extend
delegate :to_param, :to => :proxy_target
instance_methods.each { |m| undef_method m unless m =~ /^(?:nil\?|send|object_id|to_a)$|^__|proxy_/ }
instance_methods.each { |m| undef_method m unless m.to_s =~ /^(?:nil\?|send|object_id|to_a)$|^__|proxy_/ }
def initialize(owner, reflection)
@owner, @reflection = owner, reflection
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册