From c1b056e22ba501d0e16bb5968d91382bf7ba708a Mon Sep 17 00:00:00 2001 From: "Alexander \"Arav\" Andreev" Date: Fri, 21 Oct 2022 02:10:18 +0400 Subject: [PATCH] Updated CAPTCHA code. --- homepage/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/homepage/index.js b/homepage/index.js index 29c7e12..5497216 100644 --- a/homepage/index.js +++ b/homepage/index.js @@ -50,7 +50,7 @@ async function getProcesses() { // 127.0.0.1:19322 async function getNewCaptcha() { try { - return await fetch("http://startpage.arav.home.arpa/captcha/").then(r => r.text()); + return await fetch("http://startpage.arav.home.arpa/captcha/", {method: "POST"}).then(r => r.text()); } catch { return null; } @@ -62,7 +62,7 @@ async function solveCaptcha(id, answer) { body.append('answer', answer); let result = fetch(`http://startpage.arav.home.arpa/captcha/${id}`, { method: "POST", body: body } ); return await result.then(r => { - return r.status == 200; + return r.status == 202; }); } catch { return false;