From 55d91ffe4c28a34f877b81c6008d287ef8c4181c Mon Sep 17 00:00:00 2001 From: Anish Lakhwara Date: Thu, 14 Sep 2023 10:44:56 -0700 Subject: [PATCH] fix: use full XPath which doesn't change --- src/site/facebook.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/site/facebook.ts b/src/site/facebook.ts index 3b71ff9..3be44eb 100644 --- a/src/site/facebook.ts +++ b/src/site/facebook.ts @@ -14,8 +14,8 @@ const Q = { commentMoreComments: "./following-sibling::div/div/div[2][@role='button'][./span/span]", viewComments: ".//h4/..//div[@role='button']", photoCommentList: "//ul[../h2]", - firstPhotoThumbnail: "//*[@id=\"mount_0_0_4m\"]/div/div[1]/div/div[3]/div/div/div/div[1]/div[1]/div/div/div[4]/div/div/div/div/div/div/div/div/div[3]/div[1]/div[1]/div/div/a", firstVideoThumbnail: "//div[@role='main']//div[contains(@style, 'z-index')]/following-sibling::div/div/div/div[last()]//a[contains(@href, '/videos/') and @aria-hidden!='true']", + firstPhotoThumbnail: "/html/body/div[1]/div/div[1]/div/div[3]/div/div/div/div[1]/div[1]/div/div/div[4]/div/div/div/div/div/div/div/div/div[3]/div[1]/div[1]/div/div/a/img", firstVideoSimple: "//div[@role='main']//a[contains(@href, '/videos/') and @aria-hidden!='true']", mainVideo: "//div[@data-pagelet='root']//div[@role='dialog']//div[@role='main']//video", nextVideo: "following::a[contains(@href, '/videos/') and @aria-hidden!='true']",