Class: CafeCar::ApplicationPolicy::Scope

Inherits:
Object
  • Object
show all
Defined in:
app/policies/cafe_car/application_policy.rb

Instance Method Summary collapse

Constructor Details

#initialize(user, scope) ⇒ Scope

Returns a new instance of Scope.



26
27
28
29
# File 'app/policies/cafe_car/application_policy.rb', line 26

def initialize(user, scope)
  @user  = user
  @scope = scope
end

Instance Method Details

#resolveObject

Raises:

  • (NoMethodError)


31
32
33
# File 'app/policies/cafe_car/application_policy.rb', line 31

def resolve
  raise NoMethodError, "You must define #resolve in #{self.class}"
end