authorize_resource is not called on the index action
Created by: westonganger
I was trying to implement my usual methods for CanCan but I was stumped for a bit why the authorize_resource
method was never getting called no matter what I did.
Turns out that authorize_resource
is never called on the index action which happened to be the page I was testing.
I was expecting the method to called with the resource_class
in place of the resource
. I suppose this could pass the scoped_resource
instead if that is preferred.
Would you accept a PR for this? If not then the documentation should be updated to include this little tidbit.