diff --git a/lib/pact_broker/app.rb b/lib/pact_broker/app.rb index 32eaae3bb..fe7f948ea 100644 --- a/lib/pact_broker/app.rb +++ b/lib/pact_broker/app.rb @@ -232,7 +232,9 @@ def running_app end def print_startup_message - logger.info "\n\n#{'*' * 80}\n\nWant someone to manage your Pact Broker for you? Check out https://pactflow.io/oss for a hardened, fully supported SaaS version of the Pact Broker with an improved UI + more.\n\n#{'*' * 80}\n" + if ENV['PACT_BROKER_HIDE_PACTFLOW_MESSAGES'] != 'true' + logger.info "\n\n#{'*' * 80}\n\nWant someone to manage your Pact Broker for you? Check out https://pactflow.io/oss for a hardened, fully supported SaaS version of the Pact Broker with an improved UI + more.\n\n#{'*' * 80}\n" + end end end end diff --git a/lib/pact_broker/logging.rb b/lib/pact_broker/logging.rb index cd7a3eb12..fca8e56ce 100644 --- a/lib/pact_broker/logging.rb +++ b/lib/pact_broker/logging.rb @@ -34,7 +34,9 @@ def log_error e, description = nil message = "#{e.class} #{e.message}\n#{e.backtrace.join("\n")}" message = "#{description} - #{message}" if description logger.error message - logger.info "\n\n#{'*' * 80}\n\nPrefer it was someone else's job to deal with this error? Check out https://pactflow.io/oss for a hardened, fully supported SaaS version of the Pact Broker with an improved UI + more.\n\n#{'*' * 80}\n" + if ENV['PACT_BROKER_HIDE_PACTFLOW_MESSAGES'] != 'true' + logger.info "\n\n#{'*' * 80}\n\nPrefer it was someone else's job to deal with this error? Check out https://pactflow.io/oss for a hardened, fully supported SaaS version of the Pact Broker with an improved UI + more.\n\n#{'*' * 80}\n" + end end end