Class: Formulary::Config
- Inherits:
-
Object
- Object
- Formulary::Config
- Defined in:
- lib/formulary/config.rb
Overview
Handles configuration
Class Method Summary collapse
Class Method Details
.drug_urls ⇒ Object
10 11 12 |
# File 'lib/formulary/config.rb', line 10 def self.drug_urls raw_config['drug_urls'] end |
.max_drugs_per_plan ⇒ Object
14 15 16 |
# File 'lib/formulary/config.rb', line 14 def self.max_drugs_per_plan raw_config['max_drugs_per_plan'] end |
.plan_urls ⇒ Object
6 7 8 |
# File 'lib/formulary/config.rb', line 6 def self.plan_urls raw_config['plan_urls'] end |
.raw_config ⇒ Object (private)
18 19 20 21 |
# File 'lib/formulary/config.rb', line 18 def self.raw_config file_path = File.join(__dir__, '..', '..', 'config.yml') @raw_config ||= YAML.safe_load(File.read(file_path)) end |