Class: ProblemPolicy::Scope

Inherits:
ApplicationPolicy::Scope show all
Defined in:
app/policies/problem_policy.rb

Instance Method Summary collapse

Methods inherited from ApplicationPolicy::Scope

#initialize

Constructor Details

This class inherits a constructor from ApplicationPolicy::Scope

Instance Method Details

#resolve ⇒ Object



18
19
20
# File 'app/policies/problem_policy.rb', line 18

def resolve
  @user.is_moderator? ? scope : scope.none
end