mirror of
https://github.com/viq/NewsBlur.git
synced 2025-09-18 21:43:31 +00:00
Python 3 doesn't leak variables from list comprehensions.
This commit is contained in:
parent
f3730b5dfc
commit
fe9272cc07
1 changed files with 1 additions and 1 deletions
|
@ -39,7 +39,7 @@ def urlize(text, trim_url_limit=None, nofollow=False, autoescape=False):
|
|||
('|'.join([re.escape(x) for x in LEADING_PUNCTUATION]),
|
||||
'|'.join([re.escape(x) for x in TRAILING_PUNCTUATION])))
|
||||
simple_email_re = re.compile(r'^\S+@[a-zA-Z0-9._-]+\.[a-zA-Z0-9._-]+$')
|
||||
del x # Temporary variable
|
||||
# del x # Temporary variable
|
||||
|
||||
def escape(html):
|
||||
return html.replace('&', '&').replace('<', '<').replace('>', '>').replace('"', '"').replace("'", ''')
|
||||
|
|
Loading…
Add table
Reference in a new issue