master
Aevann1 2021-12-10 20:46:20 +02:00
parent 1276bc3531
commit e005b8b06b
1 changed files with 2 additions and 1 deletions

View File

@ -262,10 +262,11 @@ def static_service(path):
return resp
@app.get('/images/<path:path>')
@app.get('/IMAGES/<path:path>')
@app.get('/hostedimages/<path:path>')
@limiter.exempt
def images(path):
resp = make_response(send_from_directory('/images', path))
resp = make_response(send_from_directory('/images', path.replace('.WEBP','.webp')))
resp.headers.remove("Cache-Control")
resp.headers.add("Cache-Control", "public, max-age=2628000")
if request.path.endswith('.webp'):