mirror of
https://iceshrimp.dev/iceshrimp/iceshrimp
synced 2024-12-11 13:18:09 +09:00
Revert "Fix bug"
This reverts commit 2ef795aba8a0dccf791000653ceea03a2ded7b26.
This commit is contained in:
parent
c59ca22a81
commit
98d1b8ffb4
@ -8,8 +8,8 @@ const requiredMongoDBVersion = [3, 6];
|
||||
export function checkMongoDB(config: Config, logger: Logger) {
|
||||
return new Promise((res, rej) => {
|
||||
const mongoDBLogger = logger.createSubLogger('db');
|
||||
const u = config.mongodb.user.map(x => encodeURIComponent(x)).getOrElse(null);
|
||||
const p = config.mongodb.pass.map(x => encodeURIComponent(x)).getOrElse(null);
|
||||
const u = config.mongodb.user ? encodeURIComponent(config.mongodb.user) : null;
|
||||
const p = config.mongodb.pass ? encodeURIComponent(config.mongodb.pass) : null;
|
||||
const uri = `mongodb://${u && p ? `${u}:****@` : ''}${config.mongodb.host}:${config.mongodb.port}/${config.mongodb.db}`;
|
||||
mongoDBLogger.info(`Connecting to ${uri} ...`);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user