lib/cc/cli.rb in codeclimate-0.24.1 vs lib/cc/cli.rb in codeclimate-0.24.2
- old
+ new
@@ -16,11 +16,15 @@
autoload :Runner, "cc/cli/runner"
autoload :Test, "cc/cli/test"
autoload :ValidateConfig, "cc/cli/validate_config"
autoload :Version, "cc/cli/version"
+ def self.debug?
+ ENV["CODECLIMATE_DEBUG"]
+ end
+
def self.debug(message, values = {})
- if ENV["CODECLIMATE_DEBUG"]
+ if debug?
if values.any?
message << " "
message << values.map { |k, v| "#{k}=#{v.inspect}" }.join(" ")
end