EppO/rolify — Issue #34: Rails 3.2 Support
Author: ajrkerr
Created: 2012-01-24 16:32:06+00:00
State: open

Hello,

Nice plugin btw, I've been using it rather successfully for a little while. I've hit a snag with upgrading for Rails 3.2, and have duplicated it with a fresh Rails 3.2 app. I load in Devise and Rolify, and I receive this exception when I try User.first.has_role(:prime)

ArgumentError: wrong number of arguments (1 for 3)
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/activerecord-3.2.0/lib/active_record/dynamic_matchers.rb:29:in `find_or_create_by_name_and_resource_type_and_resource_id'
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/rolify-2.2.0/lib/rolify/role.rb:38:in `has_role'
from (irb):2
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/railties-3.2.0/lib/rails/commands/console.rb:47:in `start'
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/railties-3.2.0/lib/rails/commands/console.rb:8:in `start'
from /usr/local/rvm/gems/ruby-1.9.2-p290/gems/railties-3.2.0/lib/rails/commands.rb:41:in `'
from script/rails:6:in `require'
from script/rails:6:in `

'

Thanks,

Adam