Skip to content

Commit

Permalink
Not using connection pool anymore as that does not support transactions
Browse files Browse the repository at this point in the history
  • Loading branch information
cdauth committed Jan 14, 2013
1 parent 102c5ef commit 099532b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion lib/database.js
Expand Up @@ -38,7 +38,8 @@ pgQuery.prototype.handleError = function(err) {
function getConnection(config, callback) {
var schema = config.schema || "public";

pg.connect(config, function(err, con) {
var con = new pg.Client(config);
con.connect(function(err) {
if(err)
return callback(err);

Expand Down
2 changes: 1 addition & 1 deletion lib/keyring.js
Expand Up @@ -55,7 +55,7 @@ function initialiseDatabase(dbConfig, callback) {
return callback(err);

structure._createStructure(con, queries, function(err) {
//con.end();
con.end();
callback(err);
});
});
Expand Down

0 comments on commit 099532b

Please sign in to comment.