Browse files

Added support for process.env.DATABASE_URL as used by heroku

  • Loading branch information...
1 parent 7e4e324 commit a554f5ea3cad306c09080df3763ae2b4f32629ed @garth garth committed Nov 16, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/driver/pg.js
View
2 lib/driver/pg.js
@@ -192,6 +192,6 @@ var PgDriver = Base.extend({
});
exports.connect = function(config, callback) {
- var db = config.db || new pg.Client(config);
+ var db = config.db || new pg.Client(process.env.DATABASE_URL || config);
callback(null, new PgDriver(db));
};

0 comments on commit a554f5e

Please sign in to comment.