fix(route/udn): Correct regex (#19033)
This commit is contained in:
parent
f8242fe166
commit
b9ca4467be
|
|
@ -53,7 +53,7 @@ async function handler(ctx) {
|
|||
let result = await got(link);
|
||||
// VIP article requires redirection
|
||||
// e.g. https://udn.com/news/story/7331/6576320
|
||||
const vip = result.data.match(/<script language=javascript>window\.location\.href="(https?:\/\/[^"]+")/);
|
||||
const vip = result.data.match(/<script language=javascript>window\.location\.href="(https?:\/\/[^"]+)"/);
|
||||
if (vip) {
|
||||
result = await got(vip[1]);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue