From fba277ce1dc8b80b990c0ec2ef9730a7464c5d6c Mon Sep 17 00:00:00 2001 From: Dan Sloan <827555+LucidDan@users.noreply.github.com> Date: Wed, 6 Mar 2019 20:28:10 +1100 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B=20Fixed=20custom=20certificate=20u?= =?UTF-8?q?sage=20for=20MySQL=20(#10573)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit closes #10570 Added a conditional to only run makePathsAbsolute when database:client is sqlite3, which keeps expected behaviour (make the "database:connection:filename" path absolute when running SQLite) while not breaking MySQL behaviour. --- core/server/config/index.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/server/config/index.js b/core/server/config/index.js index 95fda5e734..d86a9900db 100644 --- a/core/server/config/index.js +++ b/core/server/config/index.js @@ -48,8 +48,9 @@ _private.loadNconf = function loadNconf(options) { nconf.sanitizeDatabaseProperties(); nconf.makePathsAbsolute(nconf.get('paths'), 'paths'); - nconf.makePathsAbsolute(nconf.get('database:connection'), 'database:connection'); - + if (nconf.get('database:client') === 'sqlite3') { + nconf.makePathsAbsolute(nconf.get('database:connection'), 'database:connection'); + } /** * Check if the URL in config has a protocol */