lib/bovem/configuration.rb in bovem-4.0.0 vs lib/bovem/configuration.rb in bovem-4.0.1
- old
+ new
@@ -21,10 +21,11 @@
#
# @attribute [r] i18n
# @return [I18n] A i18n helper.
class Configuration < Lazier::Configuration
attr_reader :i18n
+
# Creates a new configuration.
#
# A configuration file is a plain Ruby file with a top-level {Configuration config} object.
#
# @param file [String] The file to read.
@@ -70,10 +71,10 @@
# :nodoc:
# rubocop:disable RescueException
def read_configuration_file(file, logger)
# Open the file
path = file =~ /^#{File::SEPARATOR}/ ? file : ::Pathname.new(file).realpath
- logger.info(i18n.configuration.using(path)) if logger
+ logger.info(i18n.using(path)) if logger
eval_file(path)
rescue Exception
raise(Bovem::Errors::InvalidConfiguration, i18n.invalid(file))
end
# rubocop:enable RescueException