Sha256: 7edbe0340bdd9f3b1bf8c8f0cdbb8f8b8fba212cb6b215f2dd95093a728e446b
Contents?: true
Size: 414 Bytes
Versions: 1
Compression:
Stored size: 414 Bytes
Contents
require 'active_support/inflector' module CanTango module PermitEngine module Util def permit_name clazz @name ||= clazz.to_s.demodulize.gsub(/Role/,'').gsub(/Permit$/, '').gsub(/Group/,'').underscore.to_sym end def role @role ||= permit_name(self.class) end def localhost_manager? Permits::Configuration.localhost_manager end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
cantango-0.8.0 | lib/cantango/permit_engine/util.rb |