Skip to content

Commit

Permalink
make more explicit the text parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
chadell committed Oct 26, 2023
1 parent 5eec491 commit 6094f3f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion circuit_maintenance_parser/parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,8 +317,9 @@ def parser_hook(self, raw: bytes, content_type: str):
if content_type in ["html", "text/html"]:
soup = bs4.BeautifulSoup(quopri.decodestring(raw), features="lxml")
content = soup.text
else:
elif content_type in ["text/plain"]:
content = self.get_text_hook(raw)

for data in self.parse_content(content):
result.append(data)
return result
Expand Down

0 comments on commit 6094f3f

Please sign in to comment.