minor: logging, update, cleaning

This commit is contained in:
2024-08-02 21:30:37 +05:30
parent aba341d7a1
commit 4035e4f070
4 changed files with 709 additions and 315 deletions

View File

@@ -12,13 +12,9 @@ const db = {};
/** @type {typedefs.Sequelize} */
let sequelize;
if (config.use_env_variable) {
sequelize = new Sequelize(process.env[config.use_env_variable], config, {
logging: (msg) => logger.debug(msg)
});
sequelize = new Sequelize(process.env[config.use_env_variable], config);
} else {
sequelize = new Sequelize(config.database, config.username, config.password, config, {
logging: (msg) => logger.debug(msg)
});
sequelize = new Sequelize(config.database, config.username, config.password, config);
}
(async () => {