Changed Jax Slayher entry ID from slug to data ID due URL conflicts.
This commit is contained in:
@@ -81,10 +81,11 @@ function scrapeAll(scenes, channel) {
|
|||||||
const release = {};
|
const release = {};
|
||||||
|
|
||||||
release.url = `${channel.origin}/tour/video/${data.slug}`;
|
release.url = `${channel.origin}/tour/video/${data.slug}`;
|
||||||
release.entryId = data.slug;
|
release.entryId = data.id; // URL slugs are not unique, some pages on original site unreachable!
|
||||||
|
|
||||||
release.attributes = {
|
release.attributes = {
|
||||||
dataEntryId: data.id, // not used in URL, store as secondary
|
dataEntryId: data.id, // not used in URL, store as secondary
|
||||||
|
slug: data.slug,
|
||||||
};
|
};
|
||||||
|
|
||||||
release.title = data.title;
|
release.title = data.title;
|
||||||
@@ -143,10 +144,11 @@ function scrapeScene(payload, { url, channel, baseRelease }) {
|
|||||||
return release;
|
return release;
|
||||||
}
|
}
|
||||||
|
|
||||||
release.entryId = new URL(url).pathname.match(/\/video\/([\w-]+)/)?.[1];
|
release.entryId = videoId;
|
||||||
|
|
||||||
release.attributes = {
|
release.attributes = {
|
||||||
dataEntryId: videoId,
|
dataEntryId: videoId,
|
||||||
|
slug: new URL(url).pathname.match(/\/video\/([\w-]+)/)?.[1],
|
||||||
};
|
};
|
||||||
|
|
||||||
release.title = videoData?.title;
|
release.title = videoData?.title;
|
||||||
|
|||||||
Reference in New Issue
Block a user