Skip to content

Commit 00159ea

Browse files
hauntsaninjakurtmckee
authored andcommitted
Fix incorrect passing of flags to re.sub
1 parent 6cdc208 commit 00159ea

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

feedparser/html.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ def feed(self, data):
149149
:rtype: None
150150
"""
151151

152-
data = re.sub(r'<!((?!DOCTYPE|--|\[))', r'&lt;!\1', data, re.IGNORECASE)
152+
data = re.sub(r"<!((?!DOCTYPE|--|\[))", r"&lt;!\1", data, flags=re.IGNORECASE)
153153
data = re.sub(r'<([^<>\s]+?)\s*/>', self._shorttag_replace, data)
154154
data = data.replace('&#39;', "'")
155155
data = data.replace('&#34;', '"')

0 commit comments

Comments
 (0)