Added gender indicator to actor tiles. Fixed PornHub scraper fetching default avatars.

This commit is contained in:
2020-01-25 01:26:13 +01:00
parent 4d53b84587
commit bceded3ebd
5 changed files with 141 additions and 87 deletions

View File

@@ -45,7 +45,7 @@ async function scrapeProfile(html, _url, actorName) {
if (bio.Piercings) profile.hasPiercings = bio.Piercings === 'Yes';
if (bio.Tattoos) profile.hasTattoos = bio.Tattoos === 'Yes';
if (avatarEl) profile.avatar = avatarEl.src;
if (avatarEl && !/default\//.test(avatarEl.src)) profile.avatar = avatarEl.src;
profile.social = Array.from(document.querySelectorAll('.socialList a'), el => el.href).filter(link => link !== 'https://www.twitter.com/'); // PH links to Twitter itself for some reason
return profile;