Skip to content

Instantly share code, notes, and snippets.

@amcintyre99
Last active December 20, 2015 03:49
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 amcintyre99/b52cc36a8b062c79eb0b to your computer and use it in GitHub Desktop.
Save amcintyre99/b52cc36a8b062c79eb0b to your computer and use it in GitHub Desktop.
var recursive = function (stmt) {
var req = request.post({url:url,oauth:oauth,timeout:10000},function(err,resp,body) {
if(err) {
console.log(err)
setTimeout(function() {
recursive(stmt)
},500)
}
})
req.on('data',function(data) {
....insert row in database - uses stmt....
})
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment