aboutsummaryrefslogtreecommitdiffstats
path: root/app.py
diff options
context:
space:
mode:
Diffstat (limited to 'app.py')
-rw-r--r--app.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/app.py b/app.py
index 2b10dcd..2cf12f4 100644
--- a/app.py
+++ b/app.py
@@ -39,8 +39,11 @@ ALLOWED_STATIC_EXTENSIONS = {
}
-def safe_url(filename):
- return quote(str(filename or ""), safe="/")
+def safe_url(url):
+ raw = str(url or "").strip()
+ if not raw:
+ return ""
+ return quote(raw, safe=":/?&=#%+~@!$,;*-._")
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage