Changed profile test to prefer network. Removed stray console from Gamma.

This commit is contained in:
DebaucheryLibrarian
2026-02-24 01:28:22 +01:00
parent ee495a5cde
commit c75c3e3ed9
2 changed files with 4 additions and 3 deletions

View File

@@ -922,6 +922,8 @@ function scrapeApiProfile(data, releases, siteSlug) {
if (releases) profile.releases = releases.map((release) => `https://${siteSlug}.com/en/video/${release.url_title}/${release.clip_id}`);
console.log(profile);
return profile;
}
@@ -956,8 +958,6 @@ async function fetchApiProfile({ name: actorName }, context, include) {
encodeJSON: true,
});
console.log(res.status, res.body.results[0].hits[0]);
if (res.status === 200 && res.body.results[0].hits.length > 0) {
const actorData = res.body.results[0].hits.find((actor) => slugify(actor.name) === slugify(actorName));

View File

@@ -329,7 +329,8 @@ const validators = {
// profiler in this context is shorthand for profile scraper
async function init() {
const entitiesBySlug = await fetchEntitiesBySlug(Object.keys(actorScrapers), { types: ['channel', 'network', 'info'], prefer: 'channel' });
// Pride Studios needs prefer network, probably works bests for most Gamma sites. Establish which scrapers need channel and why.
const entitiesBySlug = await fetchEntitiesBySlug(Object.keys(actorScrapers), { types: ['channel', 'network', 'info'], prefer: 'network' });
await Object.entries(actorScrapers).reduce(async (chain, [entitySlug, scraper]) => {
await chain;