We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 22156cb commit f3e916cCopy full SHA for f3e916c
1 file changed
plugins/multisrc/readnovelfull/template.ts
@@ -524,6 +524,15 @@ export class ReadNovelFullPlugin implements Plugin.PluginBase {
524
novel.chapters = [];
525
} else {
526
const ajaxBody = await ajaxResult.text();
527
+ let ajaxHtml = ajaxBody;
528
+ try {
529
+ const json = JSON.parse(ajaxBody);
530
+ if (typeof json.html === 'string') {
531
+ ajaxHtml = json.html;
532
+ }
533
+ } catch {
534
+ // eslint
535
536
const ajaxChapters: Plugin.ChapterItem[] = [];
537
let tempAjaxChapter: Partial<Plugin.ChapterItem> = {};
538
@@ -578,7 +587,7 @@ export class ReadNovelFullPlugin implements Plugin.PluginBase {
578
587
},
579
588
});
580
589
581
- ajaxParser.write(ajaxBody);
590
+ ajaxParser.write(ajaxHtml);
582
591
ajaxParser.end();
583
592
novel.chapters = ajaxChapters;
584
593
}
0 commit comments