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:
commit
c3f2d09a0e
1 changed files with 1 additions and 5 deletions
|
@ -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
|
||||
|
||||
|
|
Loading…
Reference in a new issue