- Defined in:
CanCanCan Ability class
Instance Method Summary collapse
#initialize(user) ⇒ Ability
A new instance of Ability.
Methods included from
Returns a new instance of Ability.
8 9 10 11 12 13 14 15
# File 'lib/generators/paid_up/install/templates/ability.rb', line 8 def initialize(user) user ||= User.new # anonymous user (not logged in) # Rails Application's initialization could go here. # can :manage, Group, user: user initialize_paid_up(user) end