Regarding layout parameters from parent and grandparent entities. Removed Evil Angel and Fantasy Massage scraper wrappers.
This commit is contained in:
@@ -622,7 +622,7 @@ async function scrapeProfiles(actor, sources, entitiesBySlug, existingProfilesBy
|
||||
const entity = entitiesBySlug[scraperSlug] || null;
|
||||
|
||||
const scraper = scrapers[scraperSlug];
|
||||
const layoutScraper = scraper?.[entity.parameters?.layout] || scraper;
|
||||
const layoutScraper = scraper?.[entity.parameters?.layout] || scraper?.[entity.parent?.parameters?.layout] || scraper?.[entity.parent?.parent?.parameters?.layout] || scraper;
|
||||
|
||||
const context = {
|
||||
...entity,
|
||||
|
||||
@@ -121,8 +121,8 @@ async function scrapeRelease(baseRelease, entities, type = 'scene') {
|
||||
};
|
||||
}
|
||||
|
||||
const scraper = scrapers.releases[entity.slug] || scrapers.releases[entity.parent?.slug];
|
||||
const layoutScraper = scraper[entity.parameters?.layout] || scraper;
|
||||
const scraper = scrapers.releases[entity.slug] || scrapers.releases[entity.parent?.slug] || scrapers.releases[entity.parent?.parent?.slug];
|
||||
const layoutScraper = scraper?.[entity.parameters?.layout] || scraper?.[entity.parent?.parameters?.layout] || scraper?.[entity.parent?.parent?.parameters?.layout] || scraper;
|
||||
|
||||
if (!layoutScraper) {
|
||||
logger.warn(`Could not find scraper for ${baseRelease.url}`);
|
||||
|
||||
@@ -118,6 +118,7 @@ async function fetchIncludedEntities() {
|
||||
SELECT
|
||||
parents.*,
|
||||
json_agg(included_entities ORDER BY included_entities.id) included_children,
|
||||
row_to_json(grandparents) AS parent,
|
||||
(SELECT json_agg(children)
|
||||
FROM entities AS children
|
||||
WHERE children.parent_id = parents.id) children
|
||||
@@ -125,10 +126,12 @@ async function fetchIncludedEntities() {
|
||||
included_entities
|
||||
LEFT JOIN
|
||||
entities AS parents ON parents.id = included_entities.parent_id
|
||||
LEFT JOIN
|
||||
entities AS grandparents ON grandparents.id = parents.parent_id
|
||||
WHERE
|
||||
included_entities.type = 'channel'
|
||||
GROUP BY
|
||||
parents.id;
|
||||
parents.id, grandparents.id;
|
||||
`, include);
|
||||
|
||||
const curatedNetworks = rawNetworks.rows.map(entity => curateEntity(entity, true));
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
'use strict';
|
||||
|
||||
const { fetchApiLatest, fetchApiUpcoming, fetchScene, fetchMovie, fetchApiProfile } = require('./gamma');
|
||||
|
||||
module.exports = {
|
||||
fetchLatest: fetchApiLatest,
|
||||
fetchProfile: fetchApiProfile,
|
||||
fetchScene,
|
||||
fetchMovie,
|
||||
fetchUpcoming: fetchApiUpcoming,
|
||||
};
|
||||
@@ -1,9 +0,0 @@
|
||||
'use strict';
|
||||
|
||||
const { fetchLatest, fetchUpcoming, fetchScene } = require('./gamma');
|
||||
|
||||
module.exports = {
|
||||
fetchLatest,
|
||||
fetchScene,
|
||||
fetchUpcoming,
|
||||
};
|
||||
@@ -735,6 +735,13 @@ module.exports = {
|
||||
fetchProfile,
|
||||
fetchScene,
|
||||
fetchUpcoming,
|
||||
api: {
|
||||
fetchLatest: fetchApiLatest,
|
||||
fetchUpcoming: fetchApiUpcoming,
|
||||
fetchProfile: fetchApiProfile,
|
||||
fetchScene,
|
||||
fetchMovie,
|
||||
},
|
||||
getPhotos,
|
||||
scrapeApiProfile,
|
||||
scrapeApiReleases,
|
||||
|
||||
@@ -18,13 +18,12 @@ const digitalplayground = require('./digitalplayground');
|
||||
const dogfart = require('./dogfart');
|
||||
const dorcel = require('./dorcel');
|
||||
const elegantangel = require('./elegantangel');
|
||||
const evilangel = require('./evilangel');
|
||||
const fakehub = require('./fakehub');
|
||||
const famedigital = require('./famedigital');
|
||||
const fantasymassage = require('./fantasymassage');
|
||||
const firstanalquest = require('./firstanalquest');
|
||||
const fcuk = require('./fcuk');
|
||||
const fullpornnetwork = require('./fullpornnetwork');
|
||||
const gamma = require('./gamma');
|
||||
const girlsway = require('./girlsway');
|
||||
const hitzefrei = require('./hitzefrei');
|
||||
const hookuphotshot = require('./hookuphotshot');
|
||||
@@ -110,14 +109,13 @@ const scrapers = {
|
||||
dogfartnetwork: dogfart,
|
||||
dorcel,
|
||||
elegantangel,
|
||||
evilangel,
|
||||
fakehub,
|
||||
famedigital,
|
||||
fantasymassage,
|
||||
fcuk,
|
||||
firstanalquest,
|
||||
forbondage: porndoe,
|
||||
fullpornnetwork,
|
||||
gamma,
|
||||
gaywire: bangbros,
|
||||
girlsway,
|
||||
girlgirl: julesjordan,
|
||||
@@ -210,7 +208,7 @@ const scrapers = {
|
||||
dorcelclub: dorcel,
|
||||
doubleviewcasting: firstanalquest,
|
||||
elegantangel,
|
||||
evilangel,
|
||||
evilangel: gamma,
|
||||
eyeontheguy: hush,
|
||||
fakehub,
|
||||
exploitedcollegegirls: fcuk,
|
||||
|
||||
@@ -209,7 +209,7 @@ async function scrapeChannel(channelEntity, accNetworkReleases) {
|
||||
|| scrapers.releases[channelEntity.parent?.slug]
|
||||
|| scrapers.releases[channelEntity.parent?.parent?.slug];
|
||||
|
||||
const layoutScraper = scraper?.[channelEntity.parameters?.layout] || scraper;
|
||||
const layoutScraper = scraper?.[channelEntity.parameters?.layout] || scraper?.[channelEntity.parent?.parameters?.layout] || scraper?.[channelEntity.parent?.parent?.parameters?.layout] || scraper;
|
||||
|
||||
if (!layoutScraper) {
|
||||
logger.warn(`No scraper found for '${channelEntity.name}' (${channelEntity.parent?.name})`);
|
||||
|
||||
Reference in New Issue
Block a user