lib/app_monit/config.rb in app_monit-0.0.4 vs lib/app_monit/config.rb in app_monit-0.0.5
- old
+ new
@@ -1,9 +1,9 @@
module AppMonit
class Config
class << self
- attr_writer :api_key, :env, :end_point, :fail_silent, :enabled
+ attr_writer :api_key, :env, :end_point, :fail_silent, :enabled, :timeout
def api_key
@api_key || raise(ApiKeyNotSetError.new("Please set your API key"))
end
@@ -19,9 +19,13 @@
@fail_silent || false
end
def enabled?
@enabled.nil? ? env != "test" : @enabled
+ end
+
+ def timeout
+ @timeout || 1
end
end
end
end