diff --git a/ppcomp/ppcomp.py b/ppcomp/ppcomp.py index 81a4ed2..98dd695 100644 --- a/ppcomp/ppcomp.py +++ b/ppcomp/ppcomp.py @@ -48,7 +48,7 @@ /* Add spaces around td tags */ td::before, td::after { content: " "; } - + /* Remove thought breaks */ .tb { display: none; } @@ -501,7 +501,7 @@ def load(self, filename): raise SyntaxError('Not an html file: ' + filename) super().load(filename) try: - if 0 <= self.text.find('', 0, 100): # limit search + if "" in self.text[:100].lower(): # limit search self.tree, errors = self.parse_html5() else: self.tree, errors = self.parse_html()