class Wallaby::ActiveRecord::PunditProvider
Pundit provider for {Wallaby::ActiveRecord}
Public Instance Methods
accessible_for(_action, scope)
click to toggle source
Filter a scope @param _action [Symbol, String] @param scope [Object] @return [Object]
# File lib/adapters/wallaby/active_record/pundit_provider.rb, line 11 def accessible_for(_action, scope) Pundit.policy_scope! user, scope rescue Pundit::NotDefinedError Logger.warn "Cannot find scope policy for `#{scope}`." scope end