diff options
author | bananaappletw | 2016-12-22 19:42:00 +0800 |
---|---|---|
committer | bananaappletw | 2016-12-22 19:42:00 +0800 |
commit | 3a091ff9a52e510c362ad57cc816599b8ae2b53a (patch) | |
tree | a46f26f25638ccd98aa60dc7f442e9eab0769709 /lib/models | |
parent | 936d922442faa5c60d6831cd350c0fc885e32bcb (diff) |
Simplify code for heroku
Diffstat (limited to 'lib/models')
-rw-r--r-- | lib/models/index.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/models/index.js b/lib/models/index.js index 1156d0f7..6fcffb5f 100644 --- a/lib/models/index.js +++ b/lib/models/index.js @@ -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); |