summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/instagram_task.ts11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/instagram_task.ts b/src/instagram_task.ts
index abe963a..2c6c6c8 100644
--- a/src/instagram_task.ts
+++ b/src/instagram_task.ts
@@ -78,13 +78,12 @@ export const runDownloadInstagramTask = async (task: InstagramTask) => {
}
}
- await page.type("input#url", task.url);
- await page.click("#btn-submit");
+ await page.type("input#input-url", task.url);
+ await page.click("#submit-btn");
- const downloadButton = await page.waitForSelector(
- ".download-content a[data-event=click_download_btn]",
- { timeout: 10_000 },
- );
+ const downloadButton = await page.waitForSelector("a[download]", {
+ timeout: 10_000,
+ });
if (!downloadButton) {
throw new Error("Could not find download button");
}