Added trailer support to Vogov. Set preferred trailer resolution to 480p. Added 480p and other resolution trailers support to XEmpire.
This commit is contained in:
@@ -137,7 +137,7 @@ async function fetchPhoto(photoUrl, index, label, attempt = 1) {
|
||||
logger.warn(`Failed attempt ${attempt}/3 to fetch photo ${index + 1} for ${label} (${photoUrl}): ${error}`);
|
||||
|
||||
if (attempt < 3) {
|
||||
await Promise.delay(1000);
|
||||
await Promise.delay(5000);
|
||||
return fetchPhoto(photoUrl, index, label, attempt + 1);
|
||||
}
|
||||
|
||||
@@ -290,7 +290,7 @@ async function storeTrailer(trailers, {
|
||||
}, label) {
|
||||
// support scrapers supplying multiple qualities
|
||||
const trailer = Array.isArray(trailers)
|
||||
? trailers.find(trailerX => [1080, 720].includes(trailerX.quality)) || trailers[0]
|
||||
? trailers.find(trailerX => [config.media.trailerQuality, 480, 720, 1080].includes(trailerX.quality)) || trailers[0]
|
||||
: trailers;
|
||||
|
||||
if (!trailer || !trailer.src) {
|
||||
|
||||
Reference in New Issue
Block a user