Hi Josh, On Tue, 2009-10-13 at 19:50 +0200, Joshua Muheim wrote: > Joshua Muheim wrote: > > Hi all > > > > I just wondered why a private before_validation method is not called > > when an ActiveRecord object is saved? When it's public, then it works... > > Why is that? In my opinion, the before_validation method should > > intuitively rather be private... > > > > Thanks > > Josh > > Nobody knows this?
Make it protected, not private. The link below should help understanding. http://weblog.jamisbuck.org/2007/2/23/method-visibility-in-ruby HTH, Bill --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" 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-talk?hl=en -~----------~----~----~----~------~----~------~--~---

