From 183f87155f19eb32c21efcf83bb543c019303d95 Mon Sep 17 00:00:00 2001 From: DebaucheryLibrarian Date: Wed, 3 Jun 2026 05:58:32 +0200 Subject: [PATCH] Fixed Channel Anal thumbnail fallbacks. --- src/scrapers/acam.js | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/src/scrapers/acam.js b/src/scrapers/acam.js index 0a8d2ed6..8cfca192 100755 --- a/src/scrapers/acam.js +++ b/src/scrapers/acam.js @@ -4,9 +4,10 @@ const unprint = require('unprint'); const slugify = require('../utils/slugify'); -function extractEntryId(poster) { +function extractEntryId(posters) { try { - return slugify(new URL(poster).pathname.match(/\/images\/(.*?)\.[a-z]{3,4}/i)?.[1]?.replace(/smak.*/i, ''), ''); + const poster = [].concat(posters).filter(Boolean)[0]; + return slugify(new URL(poster.src || poster).pathname.match(/\/images\/(.*?)\.[a-z]{3,4}/i)?.[1]?.replace(/smak.*/i, ''), ''); } catch (error) { return null; } @@ -48,14 +49,26 @@ function getPhotos(poster) { if (photo === poster) { return { - poster, + poster: { + src: poster, + verifyType: 'image', + }, photos: [], }; } return { - poster: [photo, poster], - photos: [poster], + poster: [{ + src: photo, + verifyType: 'image', + }, { + src: poster, + verifyType: 'image', + }], + photos: [{ + src: poster, + verifyType: 'image', + }], }; }