Replaced queueMethod in media sources for new interval/concurrency options.

This commit is contained in:
DebaucheryLibrarian
2020-11-23 00:38:22 +01:00
parent aa1bba84aa
commit 8688c28d0f
3 changed files with 23 additions and 12 deletions

View File

@@ -28,14 +28,16 @@ function scrapeLatest(html, site) {
src: /^http/.test(poster) ? poster : `https:${poster}`,
referer: site.url,
attempts: 5,
queueMethod: '5s',
interval: 5000,
concurrency: 1,
};
release.photos = Array.from(scene.querySelectorAll('.rollover-thumbs img'), el => ({
src: (/^http/.test(el.dataset.src) ? el.dataset.src : `https:${el.dataset.src}`),
referer: site.url,
attempts: 5,
queueMethod: '5s',
interval: 5000,
concurrency: 1,
}));
if (teaserEl) {
@@ -43,7 +45,8 @@ function scrapeLatest(html, site) {
src: teaserEl.dataset.src,
referer: site.url,
attempts: 5,
queueMethod: '5s',
interval: 5000,
concurrency: 1,
};
}
@@ -76,7 +79,8 @@ function scrapeScene(html, site, url) {
src: (/^http/.test(el.src) ? el.src : `https:${el.src}`),
referer: site.url,
attempts: 5,
queueMethod: '5s',
interval: 5000,
concurrency: 1,
}));
const posterEl = scene.querySelector('#no-player-image');
@@ -88,14 +92,16 @@ function scrapeScene(html, site, url) {
src: /^http/.test(posterEl.src) ? posterEl.src : `https:${posterEl.src}`,
referer: site.url,
attempts: 5,
queueMethod: '5s',
interval: 5000,
concurrency: 1,
};
} else if (videoEl) {
release.poster = {
src: /^http/.test(videoEl.poster) ? videoEl.poster : `https:${videoEl.poster}`,
referer: site.url,
attempts: 5,
queueMethod: '5s',
interval: 5000,
concurrency: 1,
};
}
@@ -104,7 +110,8 @@ function scrapeScene(html, site, url) {
src: trailerEl.src,
referer: site.url,
attempts: 5,
queueMethod: '5s',
interval: 5000,
concurrency: 1,
};
}