Andy Jeffries wrote: > > I'd say it depends on whether Y really IS AN X. If not, but they have > similar roles, I'd say you're better of doing this: > > class Z < ApplicationController > def some_method > ... > end > end > > class X < Z > ... > end > > class Y < Z > ... > end > I like this if ALL your controllers should have access to some_method
> module Z > def some_method > ... > end > end > > class X < ApplicationController > include Z > ... > end > > class Y < ApplicationController > include Z > ... > end > I like this if some_method should only be available to some controllers. Depends on the application requirements as to which way I would go... -- Posted via http://www.ruby-forum.com/. -- 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.

