Skip to content

Instantly share code, notes, and snippets.

@jamespeerless
Created December 16, 2013 20:03
Show Gist options
  • Save jamespeerless/7993396 to your computer and use it in GitHub Desktop.
Save jamespeerless/7993396 to your computer and use it in GitHub Desktop.
var client = {
query: function(text, values, cb){
pg.connect(conString, function(err, cl, done){
if(err){
setTimeout(function(){client.query(text,values,cb);}, 250);
} else {
cl.query(text, values, function(err, result){
done();
cb(err, result);
});
}
});
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment