Registry / auth / pundit

pundit

JSON →
library2.5.2rbrubygemsunverified

Object oriented authorization for Rails applications, providing a set of helpers and policies.

gem install pundit
INSTALL
IMPORT
SIG · PUNDIT
P
pundit
authrubyv2.5.2
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

Pundit
require 'pundit'

Define an authorization policy for a Post model using Pundit.

require 'pundit' class PostPolicy def initialize(user, post) @user = user @post = post end def update? @user.admin? || @post.author == @user end end
Debug
Known issues

No known issues recorded.

Upgrade
Version history
2.5.2latest on RubyGems
Audit
Dependencies

No dependency data recorded yet.

Agent activity
20 hits · last 30 days
node
18
Amazon
1
Resources
pundit — gem install pundit · libregistry