Merge pull request #1138 from Rrrrrrray/fixStrategy

fix:攻略4无法下载常驻角色攻略导致报错
This commit is contained in:
Le 2023-02-01 09:01:26 +08:00 committed by GitHub
commit 0f89314277
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -157,7 +157,7 @@ export class strategy extends plugin {
if (group == 4) {
if (val.post.structured_content.includes(name + '】')) {
let content = val.post.structured_content.replace(/\\\/\{\}/g, '')
let pattern = new RegExp(name + '】.*?image":"(.*?)"')
let pattern = new RegExp(name + '】.*?image\\\\?":\\\\?"(.*?)\\\\?"'); // 常驻角色兼容
let imgId = pattern.exec(content)[1]
for (let image of val.image_list) {
if (image.image_id == imgId) {