Question, can you have private
and protected
in a single Ruby on Rails controller? If not, which one is preferred in a devise
controller, or a regular controller for a model?
Thanks
can you have private and protected in a single Ruby on Rails controller?
Yes, you can. Rails controllers are just classes, and classes can have any number and combination of private
and protected
blocks.