Simplify code for heroku
This commit is contained in:
parent
936d922442
commit
3a091ff9a5
1 changed files with 2 additions and 1 deletions
|
@ -14,8 +14,9 @@ dbconfig.logging = config.debug ? logger.info : false;
|
|||
|
||||
var sequelize = null;
|
||||
|
||||
// Heroku specific
|
||||
if (process.env.DATABASE_URL)
|
||||
sequelize = new Sequelize(process.env.DATABASE_URL, dbconfig.username, dbconfig.password, dbconfig);
|
||||
sequelize = new Sequelize(process.env.DATABASE_URL);
|
||||
else
|
||||
sequelize = new Sequelize(dbconfig.database, dbconfig.username, dbconfig.password, dbconfig);
|
||||
|
||||
|
|
Loading…
Reference in a new issue