Sha256: e157836f9d80f985b000f6b4a3cb188c506b1e7300a68d833a90dd68435fe748
Contents?: true
Size: 674 Bytes
Versions: 3
Compression:
Stored size: 674 Bytes
Contents
module CanTango module Loader class Yaml attr_accessor :file_name def self.inherited subclass subclass.extend ClassMethods end def parser raise NotImplementedError end def yml_content YAML.load_file(file_name) rescue raise "Couldn't load permissions file: #{file_name}. Either disable Permission engine or add this file." end module ClassMethods protected def config_file name File.join(config_path, "#{name}.yml") if rails? end def config_path CanTango.config.permissions.config_path end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
cantango-core-0.1.2 | lib/cantango/loader/yaml.rb |
cantango-core-0.1.1 | lib/cantango/loader/yaml.rb |
cantango-core-0.1.0 | lib/cantango/loader/yaml.rb |