diff --git a/lib/config/index.js b/lib/config/index.js index f5334749d..6aec63608 100644 --- a/lib/config/index.js +++ b/lib/config/index.js @@ -16,5 +16,9 @@ dotenv.config({ dotenvExpand(process.env); const res = Object.assign({}, camelify(config), camelify(process.env)); -res.caCert = (() => {return res.caCert ? fs.readFileSync(path.resolve(process.cwd(), res.caCert)) : undefined;})(), + +if (res.caCert) { + res.caCert = fs.readFileSync(path.resolve(process.cwd(), res.caCert)); +} + module.exports = res;