forked from rDrama/rDrama
keep twitter params for search
parent
844098ebfc
commit
7d926e56c9
|
@ -23,8 +23,6 @@ description_regex = re.compile("[^<>&\n\t]{1,300}", flags=re.A)
|
|||
|
||||
badge_name_regex = re.compile("[A-Za-z0-9 ]+", flags=re.A)
|
||||
|
||||
twitter_regex = re.compile("(https:\/\/twitter.com\/[A-Za-z0-9_/]+)\?[^\s)]*", flags=re.A)
|
||||
|
||||
valid_sub_regex = re.compile("^[a-zA-Z0-9_\-]{3,25}$", flags=re.A)
|
||||
|
||||
query_regex = re.compile("(\w+):(\S+)", flags=re.A)
|
||||
|
|
|
@ -367,8 +367,6 @@ def sanitize(sanitized, golden=True, limit_pings=0, showmore=True, count_marseys
|
|||
|
||||
sanitized = normalize_url(sanitized)
|
||||
|
||||
sanitized = twitter_regex.sub(r'\1', sanitized)
|
||||
|
||||
if '```' not in sanitized and '<pre>' not in sanitized:
|
||||
sanitized = linefeeds_regex.sub(r'\1\n\n\2', sanitized)
|
||||
|
||||
|
|
Loading…
Reference in New Issue