diff options
author | bananaappletw | 2016-12-22 21:20:43 +0800 |
---|---|---|
committer | bananaappletw | 2016-12-22 21:51:48 +0800 |
commit | 96fb3743f31acca0c6b272de3e8656384c2cda89 (patch) | |
tree | 52e374edaa1b5090bcacf33b10dbd46482b89666 /lib/models | |
parent | 3a091ff9a52e510c362ad57cc816599b8ae2b53a (diff) |
Use dburl to configurate
Diffstat (limited to '')
-rw-r--r-- | lib/models/index.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/models/index.js b/lib/models/index.js index 6fcffb5f..de6cd13c 100644 --- a/lib/models/index.js +++ b/lib/models/index.js @@ -15,8 +15,8 @@ dbconfig.logging = config.debug ? logger.info : false; var sequelize = null; // Heroku specific -if (process.env.DATABASE_URL) - sequelize = new Sequelize(process.env.DATABASE_URL); +if (config.dburl) + sequelize = new Sequelize(config.dburl, dbconfig); else sequelize = new Sequelize(dbconfig.database, dbconfig.username, dbconfig.password, dbconfig); |