mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2026-02-12 16:00:27 +00:00
style: RegExec match->exec
This commit is contained in:
@@ -166,7 +166,7 @@ export class NTQQWebApi {
|
||||
let resJson;
|
||||
try {
|
||||
const res = await RequestUtil.HttpGetText(url, 'GET', '', { 'Cookie': this.cookieToString(cookieObject) });
|
||||
const match = res.match(/window\.__INITIAL_STATE__=(.*?);/);
|
||||
let match = /window\.__INITIAL_STATE__=(.*?);/.exec(res);
|
||||
if (match) {
|
||||
resJson = JSON.parse(match[1].trim());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user