Added to check if url exists and to exit if it doesnt on article extractor

This commit is contained in:
Brandon Rozek 2016-08-17 16:20:01 -04:00
parent d06f585ade
commit 7defad2af6

View file

@ -16,6 +16,9 @@ module.exports = new Command("ExtractArticle", condition, function(text, send, u
}
return false;
});
if (url == undefined) {
return;
}
read(url, function(err, article, meta) {
send(article.textBody);
article.close()