mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-06 05:55:48 +01:00
fixed #2582
This commit is contained in:
@@ -44,6 +44,12 @@ questions.main = [
|
|||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
|
||||||
|
questions.optional = [
|
||||||
|
{
|
||||||
|
name: 'port',
|
||||||
|
default: 4567
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
function checkSetupFlag(next) {
|
function checkSetupFlag(next) {
|
||||||
var setupVal;
|
var setupVal;
|
||||||
@@ -149,11 +155,11 @@ function setupConfig(next) {
|
|||||||
var config = {},
|
var config = {},
|
||||||
redisQuestions = require('./database/redis').questions,
|
redisQuestions = require('./database/redis').questions,
|
||||||
mongoQuestions = require('./database/mongo').questions,
|
mongoQuestions = require('./database/mongo').questions,
|
||||||
question, x, numQ, allQuestions = questions.main.concat(redisQuestions).concat(mongoQuestions);
|
question, x, numQ, allQuestions = questions.main.concat(questions.optional).concat(redisQuestions).concat(mongoQuestions);
|
||||||
|
|
||||||
for(x=0,numQ=allQuestions.length;x<numQ;x++) {
|
for(x=0,numQ=allQuestions.length;x<numQ;x++) {
|
||||||
question = allQuestions[x];
|
question = allQuestions[x];
|
||||||
config[question.name] = install.values[question.name] || question['default'] || '';
|
config[question.name] = install.values[question.name] || question['default'] || undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
configureDatabases(null, config, DATABASES, function(err, config) {
|
configureDatabases(null, config, DATABASES, function(err, config) {
|
||||||
|
|||||||
Reference in New Issue
Block a user