diff options
author | Florrie <towerofnix@gmail.com> | 2018-06-29 19:44:44 -0300 |
---|---|---|
committer | Florrie <towerofnix@gmail.com> | 2018-06-29 19:44:44 -0300 |
commit | e4bccdfdef777747a541693796fe598491498aed (patch) | |
tree | c314241b63a5ea2411611a2ebd2141e4d7733ef8 /crawlers.js | |
parent | 2d41fd5ce9e2c821ea4da8a6650f445dbf48d641 (diff) |
Remove cheerio, disable crawl-http
Diffstat (limited to 'crawlers.js')
-rw-r--r-- | crawlers.js | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/crawlers.js b/crawlers.js index caf3c0e..5a4987a 100644 --- a/crawlers.js +++ b/crawlers.js @@ -2,7 +2,6 @@ const fs = require('fs') const path = require('path') const naturalSort = require('node-natural-sort') const fetch = require('node-fetch') -const cheerio = require('cheerio') const url = require('url') const { downloadPlaylistFromOptionValue, promisifyProcess } = require('./general-util') const { spawn } = require('child_process') @@ -26,6 +25,7 @@ function sortIgnoreCase(sortFunction) { } } +/* TODO: Removed cheerio, so crawl-http no longer works. function crawlHTTP(absURL, opts = {}, internals = {}) { // Recursively crawls a given URL, following every link to a deeper path and // recording all links in a tree (in the same format playlists use). Makes @@ -217,13 +217,14 @@ allCrawlers.crawlHTTP = crawlHTTP function getHTMLLinks(text) { // Never parse HTML with a regex! - const $ = cheerio.load(text) + // const $ = cheerio.load(text) return $('a').get().map(el => { const $el = $(el) return [$el.text(), $el.attr('href')] }) } +*/ function crawlLocal(dirPath, extensions = [ 'ogg', 'oga', |