Skip to content
This repository has been archived by the owner on Jan 19, 2024. It is now read-only.

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
achauve committed Nov 23, 2023
1 parent 4da66e7 commit 05b9f74
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions src/db/models/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,16 @@ import dbConfig from "../config/config";
import config from "../../services/config";
import psychologist from "./psychologist";

export const sequelize = new Sequelize(dbConfig.url, {
...dbConfig,
define: {
freezeTableName: true,
},
logging: config.postgre.logging ? console.log : false,
});
export const sequelize = new Sequelize(
dbConfig.url || "postgres://localhost:5432/monpsysante",
{
...dbConfig,
define: {
freezeTableName: true,
},
logging: config.postgre.logging ? console.log : false,
}
);

export const models = {
Psychologist: psychologist(sequelize),
Expand Down

0 comments on commit 05b9f74

Please sign in to comment.