mirror of
https://github.com/knightcrawler-stremio/knightcrawler.git
synced 2024-12-20 03:29:51 +00:00
[scraper] rework scraper scheduling and added seeders updating
This commit is contained in:
@@ -24,9 +24,7 @@ async function scrape() {
|
||||
}
|
||||
|
||||
async function updateSeeders(torrent) {
|
||||
return limiter.schedule(() => yts.torrent(torrent.torrentId)
|
||||
.then(records => records.map(record => ({ ...record, provider: NAME })))
|
||||
.then(records => Promise.all(records.map(record => updateTorrentSeeders(record)))));
|
||||
return limiter.schedule(() => yts.torrent(torrent.torrentId));
|
||||
}
|
||||
|
||||
async function scrapeLatestTorrents() {
|
||||
|
||||
Reference in New Issue
Block a user