mirror of
https://github.com/clarencechaan/ufc-cal.git
synced 2026-10-19 00:38:30 -07:00
Compare commits
1
Commits
1a354c2eab
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
efcf7c17e2 |
+3
-3
@@ -160,16 +160,16 @@ async function getDetailsFromEventURL(url: URL) {
|
||||
console.log(`\nGetting details from url: ${url.href}`);
|
||||
|
||||
const mainCardElements = root.querySelectorAll(
|
||||
"#main-card--2 .l-listing__item"
|
||||
"#main-card .l-listing__item"
|
||||
);
|
||||
// Check if main card and prelims have been announced
|
||||
if (mainCardElements.length) {
|
||||
// Main card has been announced, extract prelims
|
||||
const prelimsElements = root.querySelectorAll(
|
||||
"#prelims-card--2 .l-listing__item"
|
||||
"#prelims-card .l-listing__item"
|
||||
);
|
||||
const earlyPrelimsElements = root.querySelectorAll(
|
||||
"#early-prelims--2 .l-listing__item"
|
||||
"#early-prelims .l-listing__item"
|
||||
);
|
||||
|
||||
mainCard = mainCardElements.map(convertLiToStr);
|
||||
|
||||
Reference in new issue
Block a user