Skip to content

Instantly share code, notes, and snippets.

@jhuttner
Created January 18, 2012 21:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jhuttner/1635784 to your computer and use it in GitHub Desktop.
Save jhuttner/1635784 to your computer and use it in GitHub Desktop.
function getName(callback) {
client.select('name from people', function(err, result) {
if (err) {
callback(err);
return;
} else {
// process result
}
});
}
// VERSUS
function getName() {
err, result = client.select('name FROM people');
if err:
return err, false;
else:
return null, result;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment