Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
var P = require("bluebird");
var request = require("request");
var requestAsync = P.promisify(request, {multiArgs: true});
request("https://example.org")
var foo = requestAsync("https://example.org").catch(function (err) {
return urls;
console.log(err);
}).then(function(response, body) {
console.log(response);
});
crawl.linksOfThePage(url).then(function (urls) {
console.log(urls);
})
@tmos

This comment has been minimized.

Copy link

@tmos tmos commented Nov 12, 2015

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.