forked from DebaucheryLibrarian/traxxx
Fixed Jules Jordan poster returning page URL.
This commit is contained in:
parent
c7947322c1
commit
1a74bdb68a
|
@ -0,0 +1,4 @@
|
|||
<!-- Generated by IcoMoon.io -->
|
||||
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
|
||||
<path d="M11.445 0.055l-8.945 8.945-2.5 7 6.995-2.5 8.95-8.945c0.5-2-2.5-5-4.5-4.5zM4.5 11l-1-1 8.5-8.5 1 1-8.5 8.5z"></path>
|
||||
</svg>
|
After Width: | Height: | Size: 264 B |
|
@ -0,0 +1,4 @@
|
|||
<!-- Generated by IcoMoon.io -->
|
||||
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
|
||||
<path d="M11.91 0c-0.159 0-0.315 0.018-0.465 0.055l-8.945 8.945-2.5 7 6.995-2.5 8.95-8.945c0.462-1.85-2.069-4.555-4.035-4.555zM6.525 12.025l-2.553-2.553 7.5-7.5 2.555 2.555-7.502 7.498z"></path>
|
||||
</svg>
|
After Width: | Height: | Size: 333 B |
|
@ -0,0 +1,5 @@
|
|||
<!-- Generated by IcoMoon.io -->
|
||||
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
|
||||
<path d="M12 8.5v5.5h-10v-10h5.5l2-2h-8c-0.825 0-1.5 0.675-1.5 1.5v11c0 0.825 0.675 1.5 1.5 1.5h11c0.825 0 1.5-0.675 1.5-1.5v-8l-2 2z"></path>
|
||||
<path d="M13.5 0l-9.5 9.5v2.5h2.5l9.5-9.5c0-1.5-1-2.5-2.5-2.5z"></path>
|
||||
</svg>
|
After Width: | Height: | Size: 353 B |
|
@ -0,0 +1,5 @@
|
|||
<!-- Generated by IcoMoon.io -->
|
||||
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 16 16">
|
||||
<path d="M12 8.5v5.5h-10v-10h5.5l2-2h-8c-0.825 0-1.5 0.675-1.5 1.5v11c0 0.825 0.675 1.5 1.5 1.5h11c0.825 0 1.5-0.675 1.5-1.5v-8l-2 2z"></path>
|
||||
<path d="M13.5 0l-9.5 9.5v2.5h2.5l9.5-9.5c0-1.5-1-2.5-2.5-2.5zM6.5 10l-0.75-0.75 7.5-7.5 0.75 0.75-7.5 7.5z"></path>
|
||||
</svg>
|
After Width: | Height: | Size: 398 B |
|
@ -169,7 +169,8 @@ async function scrapeScene({ html, query }, context) {
|
|||
release.tags = query.contents('.update_tags a, .player-scene-description a[href*="/categories"]');
|
||||
release.director = release.tags?.find((tag) => ['mike john', 'van styles'].includes(tag?.trim().toLowerCase()));
|
||||
|
||||
const posterPath = query.poster('#video-player') || html.match(/useimage = "(.*)"/)?.[1];
|
||||
const posterPath = query.poster('#video-player', { forceGetAttribute: true }) // without getAttribute, missing poster is returned as page URL
|
||||
|| html.match(/useimage = "(.*)"/)?.[1];
|
||||
|
||||
if (posterPath) {
|
||||
const poster = /^http/.test(posterPath) ? posterPath : `${context.entity.url}${posterPath}`;
|
||||
|
@ -188,7 +189,7 @@ async function scrapeScene({ html, query }, context) {
|
|||
query.video('source[data-bitrate="trailer_720" i]'),
|
||||
query.video('source[data-bitrate="trailer" i]'), // also seems to be 720p
|
||||
query.video('source[data-bitrate="trailer_mobile" i]'), // also seems to be 720p
|
||||
];
|
||||
].filter(Boolean);
|
||||
} else if (context.include.trailers && context.entity.slug !== 'manuelferrara') {
|
||||
release.trailer = extractLegacyTrailer(html, context);
|
||||
}
|
||||
|
@ -198,7 +199,8 @@ async function scrapeScene({ html, query }, context) {
|
|||
release.photos = getPhotos(query, release, context);
|
||||
} else {
|
||||
// base release photos are usually better, but deep photos have additional thumbs
|
||||
// the filenames are not chronological, so sorting after appending only worsens the mix
|
||||
// the filenames are not chronological, so sorting after appending only worsens the mix.
|
||||
// #images img selects a list of images that is present on every page; the JJ website removes the ones that failed to load with JS (lol)
|
||||
release.photos = [
|
||||
...context.baseRelease?.photos?.map((sources) => sources.at(-1).src) || [],
|
||||
...query.imgs('#images img'),
|
||||
|
|
Loading…
Reference in New Issue