Module: PunditRolePlay
- Defined in:
- lib/pundit_role_play.rb,
lib/pundit_role_play/role.rb,
lib/pundit_role_play/railtie.rb,
lib/pundit_role_play/version.rb,
lib/pundit_role_play/permissions.rb,
lib/pundit_role_play/adapter/pundit.rb,
lib/pundit_role_play/adapter/active_record.rb,
lib/generators/pundit_role_play/role/role_generator.rb,
lib/generators/pundit_role_play/install/install_generator.rb
Defined Under Namespace
Modules: Adapter, Generators
Classes: Error, Permissions, Railtie, Role, RoleNotFoundError
Constant Summary
collapse
- VERSION =
"0.1.0"
Class Method Summary
collapse
Class Method Details
.register_role(name) ⇒ Object
21
22
23
24
|
# File 'lib/pundit_role_play.rb', line 21
def self.register_role(name)
roles << name unless name == "ApplicationRole"
roles.uniq!
end
|
.roles ⇒ Object
17
18
19
|
# File 'lib/pundit_role_play.rb', line 17
def self.roles
@roles ||= []
end
|