views:

113

answers:

1

I'm currenty trying to integrate the rails-authorization plugin into a rails application. I've followed through the installation and setup steps but each time I try to use the

permit "role"

or

permit? "role"

functions, I get an error thrown up along the lines of 'const missing, User#RolesUser' which doesn't appear to have any use in the plugin at all (It uses a Role model and a RolesUsers table). Has anyone else come across this issue at all?

+1  A: 

Eventually found that this seems to be a bug using this plugin with rails 2.2.2. Also found that changing all references of

:roles_users

to

:role_users

in the plugin lib files (specifically the object_roles_table.rb file), the migration generated and in the Roles model generated then the plugin works correctly.

workmad3