Fix events not being split up by main card, prelims, early prelims

This commit is contained in:
Clarence Chan committed 2026-09-12 15:43:04 -04:00
1 parent a910989dfc
commit 8b64eaf064
1 file changed
+3 -3
+3 -3
View File
@@ -160,16 +160,16 @@ async function getDetailsFromEventURL(url: URL) {
console.log(`\nGetting details from url: ${url.href}`); console.log(`\nGetting details from url: ${url.href}`);
const mainCardElements = root.querySelectorAll( const mainCardElements = root.querySelectorAll(
"#main-card .l-listing__item" "#main-card--2 .l-listing__item"
); );
// Check if main card and prelims have been announced // Check if main card and prelims have been announced
if (mainCardElements.length) { if (mainCardElements.length) {
// Main card has been announced, extract prelims // Main card has been announced, extract prelims
const prelimsElements = root.querySelectorAll( const prelimsElements = root.querySelectorAll(
"#prelims-card .l-listing__item" "#prelims-card--2 .l-listing__item"
); );
const earlyPrelimsElements = root.querySelectorAll( const earlyPrelimsElements = root.querySelectorAll(
"#early-prelims .l-listing__item" "early-prelims--2 .l-listing__item"
); );
mainCard = mainCardElements.map(convertLiToStr); mainCard = mainCardElements.map(convertLiToStr);