James Gray
3/8/2006 1:54:00 PM
On Mar 8, 2006, at 1:38 AM, n8agrin@gmail.com wrote:
> I spent a whole night trying to figure out why a module I was
> including
> wasn't producing any results.
>
> I finally narrowed it down to this bit of code in the module:
>
> def self.included(base)
> base.send :current_user, :logged_in?, :user?
> end
>
> For some reason, commenting it out lets everything run fine, and it
> seems that leaving it in causes the module to fail silently.
The default included() is what adds the methods, so you need to add a
call to super to keep that behavior.
James Edward Gray II