Fixed unnecessary property errors, updated unprint to address HTTP JSON response header issue.

This commit is contained in:
DebaucheryLibrarian
2025-03-07 06:03:45 +01:00
parent 022063ebd3
commit f770960191
4 changed files with 7 additions and 7 deletions

View File

@@ -86,7 +86,7 @@ function scrapeAll(scenes, channel) {
}
async function fetchLatest(channel, page = 1) {
if (!channel.parameters.studioId) {
if (!channel.parameters?.studioId) {
return null;
}

View File

@@ -123,7 +123,7 @@ async function scrapeReleases(scraper, entity, preData, isUpcoming) {
? await scraper.fetchUpcoming(entity, page, options, preData)
: await scraper.fetchLatest(entity, page, options, preData);
const pageReleases = rawPageReleases.scenes || rawPageReleases;
const pageReleases = rawPageReleases?.scenes || rawPageReleases;
if (!Array.isArray(pageReleases)) {
// scraper is unable to fetch the releases and returned a HTTP code or null