controller param from route with custom controller option set #46

aka47 opened this Issue Mar 17, 2010 · 2 comments

2 participants


in rails 2.3.5 controller with a custom controller option in the routes, the controller has the format
:controller => "NameSpace::MyController" instead of :controller => "name_space/my_controller"

in routes
map.resource "name", :controller => "NameSpace::MyController"

this raises an exception in controller_resource in model_instance, because of resource_authorization on line 51 ...

NameError: `@NameSpace::MyController' is not allowed as an instance variable name in ancan-1.0.2/lib/cancan/controller_resource.rb:27


Looks like I need to use :: as a split in the :controller parameter. Thanks for reporting this issue.


properly handle Admin::AbilitiesController in params[:controller] - closed by f2a1695

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment