In rails >4.0.0 generators creates CRUD operations with before_action
not before_filter
. It seems to do the same thing. So what's the difference between these two?
As we can see in ActionController::Base
, before_action
is just a new syntax for before_filter
.
However all before_filters
syntax are deprecated in Rails 5.0 and will be removed in Rails 5.1