Added Bang Bros data (no scraper yet). Added 21Sextury scene fetch date fallback.

This commit is contained in:
2019-04-10 03:42:20 +02:00
parent 194c6d1cca
commit bc01cbe6dc
10 changed files with 566 additions and 11 deletions

View File

@@ -63,7 +63,11 @@ async function scrapeScene(html, url, site) {
const entryId = new URL(url).pathname.split('/').slice(-1)[0];
const title = data.name;
const date = moment.utc(data.dateCreated, 'YYYY-MM-DD').toDate();
const dataDate = moment.utc(data.dateCreated, 'YYYY-MM-DD');
const date = dataDate.isValid()
? dataDate.toDate()
: moment.utc(sceneElement.find('.updatedDate').text().trim(), 'MM-DD-YYYY').toDate();
const actors = data.actor
.sort(({ gender: genderA }, { gender: genderB }) => {