Fix 500 on invalid paths

This commit is contained in:
Mia Herkt 2022-12-01 01:26:32 +01:00
parent 7661216bc0
commit ed84d3752c
No known key found for this signature in database
GPG Key ID: 72E154B8622EC191

View File

@ -408,6 +408,10 @@ def get(path):
path = Path(path.split("/", 1)[0])
sufs = "".join(path.suffixes[-2:])
name = path.name[:-len(sufs) or None]
if "." in name:
abort(404)
id = su.debase(name)
if sufs: