lib/nutrella/configuration.rb in nutrella-1.5.3 vs lib/nutrella/configuration.rb in nutrella-1.5.4
- old
+ new
@@ -18,10 +18,11 @@
# Optional Configuration
organization: #{NULOGY_ORGANIZATION_ID}
launch_command: open $url$
enable_trello_app: false
enable_logging: false
+ cache_capacity: 5
YAML
attr_reader :path, :values
def self.values(path)
@@ -34,18 +35,19 @@
load_configuration unless configuration_missing?
end
private
- def load_configuration # rubocop:disable Metrics/MethodLength
+ def load_configuration # rubocop:disable Metrics/AbcSize, Metrics/MethodLength
@values = {
key: configuration.fetch("key"),
secret: configuration.fetch("secret"),
token: configuration.fetch("token"),
organization: configuration.fetch("organization", NULOGY_ORGANIZATION_ID),
launch_command: configuration.fetch("launch_command", "open $url$"),
enable_trello_app: configuration.fetch("enable_trello_app", "false"),
- enable_logging: configuration.fetch("enable_logging", "false")
+ enable_logging: configuration.fetch("enable_logging", "false"),
+ cache_capacity: configuration.fetch("cache_capacity", 5)
}
rescue => e
abort "#{path} #{e}"
end