Apply manual rubocop fixes
This commit is contained in:
@ -9,7 +9,7 @@ module CodeOcean
|
||||
def read(options = {})
|
||||
path = Rails.root.join('config', "#{@filename}.yml#{options[:erb] ? '.erb' : ''}")
|
||||
if ::File.exist?(path)
|
||||
content = options[:erb] ? YAML.safe_load(ERB.new(::File.new(path, 'r').read).result) : YAML.load_file(path)
|
||||
content = options[:erb] ? YAML.safe_load(ERB.new(::File.new(path, 'r').read).result, aliases: true, permitted_classes: [Range]) : YAML.load_file(path)
|
||||
content[Rails.env].with_indifferent_access
|
||||
else
|
||||
raise Error.new("Configuration file not found: #{path}")
|
||||
|
Reference in New Issue
Block a user