> class Foo < ActiveRecord::Base > > private > > # really protect attribute bar > def bar > read_attribute :bar > end > def bar=(val) > write_attribute :bar, val > end > > end > > Now Foo.new.respond_to?(:bar) really _should_ return false
respond_to? is a Ruby core object method, it's not implemented by Rails. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en -~----------~----~----~----~------~----~------~--~---
