FWN: better regex + another case (#1207)
* FWN: better regex + another case * lint * forgot last case
This commit is contained in:
@@ -116,13 +116,10 @@ class FreeWebNovel implements Plugin.PluginBase {
|
|||||||
const chapterText = loadedCheerio('div.txt').html() || '';
|
const chapterText = loadedCheerio('div.txt').html() || '';
|
||||||
return chapterText
|
return chapterText
|
||||||
.replace(
|
.replace(
|
||||||
/(?:(?<=<p>\s*)(?:This (?:chapter is updated by|content is taken from)|Follow current novels on) )?[ƒfF][Rrɾг][Eēeё][Eēёe][Wwω][Eёēe][Bbɓ][Nnɳη][Oø૦ѳσo][Vѵv][Eёeē][Llℓɭ]\.\s?[Cƈcç][O૦σøoѳ][M๓ɱm]\.?/g,
|
/<p>\s*(?:(?:This (?:chapter is updated by|content is taken from)|Follow current novels on|Updated from) )?(?:[ƒfF][Rrɾг][Eēeё][Eēёe][Wwω][Eёēe][Bbɓ][Nnɳη][Oø૦ѳσo][Vѵv][Eёeē][LlℓɭI\|]\.\s?[Cƈcç][O૦σøoѳ][M๓ɱm]|ꜰʀᴇᴇᴡᴇʙɴᴏᴠᴇʟ)\.?/g,
|
||||||
'',
|
'<p>',
|
||||||
)
|
)
|
||||||
.replace(
|
.replace(/<p>\s*Visit for the best novel reading experience\.?/g, '<p>');
|
||||||
/(?<=<p>\s*)Visit for the best novel reading experience\.?/g,
|
|
||||||
'',
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
async searchNovels(searchTerm: string): Promise<Plugin.NovelItem[]> {
|
async searchNovels(searchTerm: string): Promise<Plugin.NovelItem[]> {
|
||||||
|
|||||||
Reference in New Issue
Block a user