forked from MarseyWorld/MarseyWorld
remove unnecessary
parent
c1fa1cbbdb
commit
06e51d1755
|
@ -125,8 +125,6 @@ image_sub_regex = re.compile(f'(?<!")(https:\/\/[\w\-.#&/=\?@%;+,:]{{5,250}}(\.|
|
|||
image_regex_extensions_no_gif = image_regex_extensions.replace('|gif', '')
|
||||
imgur_regex = re.compile(f'^(https:\/\/i\.imgur\.com\/[a-z0-9]+)\.({image_regex_extensions_no_gif})', flags=re.I|re.A)
|
||||
|
||||
giphy_regex = re.compile('(https:\/\/media\.giphy\.com\/media\/[a-z0-9]+\/giphy)\.gif', flags=re.I|re.A)
|
||||
|
||||
rumble_regex = re.compile('https://rumble\.com/embed/([a-zA-Z0-9]*)(/\?pub=([a-zA-Z0-9]*))?', flags=re.I|re.A)
|
||||
|
||||
twitch_regex = re.compile('(https:\/\/)?(www\.)?twitch.tv\/(.*)', flags=re.I|re.A)
|
||||
|
|
|
@ -787,8 +787,6 @@ def normalize_url(url):
|
|||
if url.endswith('.amp'):
|
||||
url = url.split('.amp')[0]
|
||||
|
||||
url = giphy_regex.sub(r'\1.webp', url)
|
||||
|
||||
if not url.startswith('/') and not url.startswith('https://rdrama.net') and not url.startswith('https://watchpeopledie.tv'):
|
||||
try: parsed_url = urlparse(url)
|
||||
except:
|
||||
|
|
Loading…
Reference in New Issue