lib/authorized_persona/authorization.rb
# Configure authorization for an authorized persona class
Configure authorization for an authorized persona class
Configure authorization for an authorized persona class
def authorized?(current_user:, action:)
        raise AuthorizedPersona::Error, "#{current_user} is not a #{authorization_persona}" unless current_user.is_a?(authorization_persona)
        current_user.authorization_tier_at_or_above?(authorized_tier(action: action))
      end
def authorized? ( current_user : , action : ) raise AuthorizedPersona :: Error , "#{current_user} is not a #{authorization_persona}" unless current_user . is_a? ( authorization_persona ) current_user . authorization_tier_at_or_above? ( authorized_tier ( action : action ) ) end
Configure authorization for an authorized persona class
Configure authorization for an authorized persona class
current_user
<not_specific>
action
<not_specific>