From adec4b00c97617eac5a24d3149a7023fb45bed19 Mon Sep 17 00:00:00 2001 From: Beth Skurrie Date: Tue, 29 Mar 2022 14:56:46 +1100 Subject: [PATCH] fix: do not set postgres connection driver options if database_statement_timeout is nil --- .../config/runtime_configuration_database_methods.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/pact_broker/config/runtime_configuration_database_methods.rb b/lib/pact_broker/config/runtime_configuration_database_methods.rb index 2bc499e7a..d22d21924 100644 --- a/lib/pact_broker/config/runtime_configuration_database_methods.rb +++ b/lib/pact_broker/config/runtime_configuration_database_methods.rb @@ -82,7 +82,7 @@ def postgres? private :postgres? def driver_options - if postgres? + if postgres? && database_statement_timeout { options: "-c statement_timeout=#{database_statement_timeout}s" } end end