1
0
Fork 0
mirror of https://github.com/varvet/pundit.git synced 2022-11-09 12:30:11 -05:00

Merge pull request #393 from ShPakvel/clean_application_policy_template

clean application_policy template
This commit is contained in:
Jonas Nicklas 2016-06-08 00:00:12 +02:00
commit c3f2d09a0e

View file

@ -11,7 +11,7 @@ class ApplicationPolicy
end
def show?
scope.where(id: record.id).exists?
false
end
def create?
@ -34,10 +34,6 @@ class ApplicationPolicy
false
end
def scope
Pundit.policy_scope!(user, record.class)
end
class Scope
attr_reader :user, :scope