forked from rDrama/rDrama
don't allow URLs with '\\' in them
parent
32a35c7066
commit
3bfe9e984b
|
@ -399,6 +399,10 @@ def filter_emojis_only(title, edit=False, graceful=False):
|
|||
else: return title.replace('\n','').strip()
|
||||
|
||||
def normalize_url(url):
|
||||
if '\\' in url:
|
||||
print(url, flush=True)
|
||||
abort(403)
|
||||
|
||||
url = reddit_domain_regex.sub(r'\1https://old.reddit.com/r/', url)
|
||||
|
||||
url = url.replace("https://youtu.be/", "https://youtube.com/watch?v=") \
|
||||
|
|
Loading…
Reference in New Issue