Class: Authorization

Inherits:
Object
  • Object
show all
Includes:
Guachiman
Defined in:
lib/generators/guachiman/install/templates/authorization.rb

Instance Method Summary collapse

Constructor Details

#initialize(current_user) ⇒ Authorization

Returns a new instance of Authorization.



4
5
6
7
8
9
10
11
# File 'lib/generators/guachiman/install/templates/authorization.rb', line 4

def initialize(current_user)
  # allow :sessions, :new, :create
  # allow :users,    :new, :create

  # allow :users, :show, :edit, :update do |user|
  #  current_user && current_user.id == user.id
  # end
end