diff --git a/circuit_maintenance_parser/parser.py b/circuit_maintenance_parser/parser.py index 4369bc04..68b9d95a 100644 --- a/circuit_maintenance_parser/parser.py +++ b/circuit_maintenance_parser/parser.py @@ -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