From 2d9243d34728fcc06fbd931b0bbd2db21cc866cb Mon Sep 17 00:00:00 2001 From: Mingye Wang Date: Sat, 17 Jan 2026 18:22:04 +0800 Subject: [PATCH] Fix regex for __RequestVerificationToken extraction Multiple token is no longer a thing. Fix #16 --- index.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/index.js b/index.js index ff59423..e794310 100644 --- a/index.js +++ b/index.js @@ -210,8 +210,7 @@ function getVerificationToken(cookieJar, callback) { return; } - // Caution: There are multiple "__RequestVerificationToken" in the body, take the right one - var regExpVerificationToken = new RegExp('[^]*
  • '); + var regExpVerificationToken = new RegExp(''); var match = body.match(regExpVerificationToken); var verificationToken = match ? match[1] : null;