mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-12-20 15:30:39 +01:00
chore: eslint prefer-template
This commit is contained in:
committed by
Julian Lam
parent
4ee0f1459d
commit
707b55b6a5
@@ -14,7 +14,7 @@ const questions = {
|
||||
};
|
||||
|
||||
module.exports = async function (config) {
|
||||
winston.info('\nNow configuring ' + config.database + ' database:');
|
||||
winston.info(`\nNow configuring ${config.database} database:`);
|
||||
const databaseConfig = await getDatabaseConfig(config);
|
||||
return saveDatabaseConfig(config, databaseConfig);
|
||||
};
|
||||
@@ -40,7 +40,7 @@ async function getDatabaseConfig(config) {
|
||||
}
|
||||
return await promptGet(questions.postgres);
|
||||
}
|
||||
throw new Error('unknown database : ' + config.database);
|
||||
throw new Error(`unknown database : ${config.database}`);
|
||||
}
|
||||
|
||||
function saveDatabaseConfig(config, databaseConfig) {
|
||||
@@ -79,7 +79,7 @@ function saveDatabaseConfig(config, databaseConfig) {
|
||||
ssl: databaseConfig['postgres:ssl'],
|
||||
};
|
||||
} else {
|
||||
throw new Error('unknown database : ' + config.database);
|
||||
throw new Error(`unknown database : ${config.database}`);
|
||||
}
|
||||
|
||||
const allQuestions = questions.redis.concat(questions.mongo).concat(questions.postgres);
|
||||
|
||||
Reference in New Issue
Block a user