Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix singleton_class?
Due to changes from http://bugs.ruby-lang.org/projects/ruby-trunk/repository/revisions/39628 current `singleton_class?` implementation fails.
Changed based on reference from http://bugs.ruby-lang.org/issues/7609
  • Loading branch information
vipulnsward committed Oct 14, 2013
1 parent 42a99db commit 8b14a6b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions activesupport/lib/active_support/core_ext/class/attribute.rb
Expand Up @@ -118,7 +118,10 @@ def class_attribute(*attrs)
end

private
def singleton_class?
ancestors.first != self

unless respond_to?(:singleton_class?)
def singleton_class?
ancestors.first != self
end
end
end

0 comments on commit 8b14a6b

Please sign in to comment.