[Rails-core] Re: Bug in Rails 2.0 when overloading a find_by method?

2008-01-19 Thread Mark Wilden
From: rubyonrails-core@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Rick DeNatale >It has to be overwriting the definition in his subclass of AR::Base, >otherwise he wouldn't have seen the problem. Let me see if I got this straight. 1) Model#find_x is defined 2) When find_x is called

[Rails-core] Re: Bug in Rails 2.0 when overloading a find_by method?

2008-01-16 Thread Mark Wilden
From: rubyonrails-core@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Rick DeNatale > No super method for find_by_ip is found, so method_missing gets called. Ah, in the calling object, not in the superclass. > (note I said overwrites rather than overrides) Thanks, that's a pet peeve

[Rails-core] Re: Bug in Rails 2.0 when overloading a find_by method?

2008-01-16 Thread Mark Wilden
From: rubyonrails-core@googlegroups.com [mailto:[EMAIL PROTECTED] On Behalf Of Jan De Poorter >When you call a dynamic finder action (in your case find_by_ip), the >ruby method_missing function is called. This magic functions takes the >function you requested and creates it, which causes your