moving expected location of setup.json to root

v1.18.x
Julian Lam 7 years ago
parent c9a989f656
commit 1d42d1a6d2

@ -242,13 +242,14 @@ function copyCSS(next) {
} }
function loadDefaults(next) { function loadDefaults(next) {
var setupDefaultsPath = path.join(__dirname, './data/setup.json'); var setupDefaultsPath = path.join(__dirname, '../setup.json');
fs.access(setupDefaultsPath, fs.constants.F_OK | fs.constants.R_OK, function (err) { fs.access(setupDefaultsPath, fs.constants.F_OK | fs.constants.R_OK, function (err) {
if (err) { if (err) {
// setup.json not found or inaccessible, proceed with no defaults // setup.json not found or inaccessible, proceed with no defaults
return setImmediate(next); return setImmediate(next);
} }
winston.info('[installer] Found setup.json, populating default values');
nconf.file({ nconf.file({
file: setupDefaultsPath, file: setupDefaultsPath,
}); });

Loading…
Cancel
Save