From baebdbc0bb0cc557906cd12d629405e3cc2173fe Mon Sep 17 00:00:00 2001 From: DebaucheryLibrarian Date: Fri, 7 Jan 2022 01:07:41 +0100 Subject: [PATCH] Adding comment listing sister sites for non-exclusive Gamma API scenes. --- src/scrapers/gamma.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/scrapers/gamma.js b/src/scrapers/gamma.js index 5e69cb75..b56781f3 100644 --- a/src/scrapers/gamma.js +++ b/src/scrapers/gamma.js @@ -237,6 +237,10 @@ async function scrapeApiReleases(json, site) { .concat(scene.categories?.map((category) => category.name)) .filter(Boolean); // some categories don't have a name + if (scene.availableOnSite.length > 1) { + release.comment = `Also available on ${scene.availableOnSite.filter((sisterSite) => sisterSite !== site.slug).join(', ')}`; + } + const posterPath = scene.pictures.resized || (scene.pictures.nsfw?.top && Object.values(scene.pictures.nsfw.top)[0]); if (posterPath) {