mirror of
https://github.com/JimmXinu/FanFicFare.git
synced 2026-04-29 10:25:43 +02:00
Update adapter_royalroadcom.py
fix for including "speak: never"; in the style
This commit is contained in:
parent
f2f333c807
commit
52a0bb6e0e
1 changed files with 1 additions and 1 deletions
|
|
@ -129,7 +129,7 @@ class RoyalRoadAdapter(BaseSiteAdapter):
|
|||
for style_element in style_elements:
|
||||
style_content = style_element.string
|
||||
if style_content and 'display: none;' in style_content.lower():
|
||||
class_matches = re.findall(r'\.(\S+)\s*\{\s*display:\s*none;\s*\}', style_content)
|
||||
class_matches = re.findall(r'\.(\S+)\s*\{\s*display:\s*none;\s*(?:speak:\s*never;\s*)?\}', style_content)
|
||||
self.styles_to_ignore.update(class_matches)
|
||||
self.handle_spoilers(soup)
|
||||
return soup
|
||||
|
|
|
|||
Loading…
Reference in a new issue