You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As of version 1.0 of node-postgres, the pg.connect callback now returns a 'done' callback which one needs to use to return the client object to the connection pool.
var pg = require('pg');
function pgConnect (callback) {
pg.connect('tcp://nodepg:password@localhost/pgstore',
function (err, client, done) {
if (err) {
console.log(JSON.stringify(err));
}
if (client) {
callback(client);
done();
}
}
);
};
The text was updated successfully, but these errors were encountered:
As of version 1.0 of node-postgres, the pg.connect callback now returns a 'done' callback which one needs to use to return the client object to the connection pool.
The text was updated successfully, but these errors were encountered: