fix logging

This commit is contained in:
lelo 2025-12-23 09:04:32 +00:00
parent cd2592a4b1
commit 08f9eef1f0

3
app.py
View File

@ -785,8 +785,7 @@ def serve_file(subpath):
# skip logging on cache hits or on audio GETs (per your rules) # skip logging on cache hits or on audio GETs (per your rules)
do_log = ( do_log = (
not is_cache_request # skip if upstream CDN asked us to cache not is_cache_request # skip if upstream CDN asked us to cache
and not is_audio_get # skip audio GETs and (request.method == 'HEAD' or not is_audio_get) # log HEADs; skip audio GETs
and request.method != 'HEAD'
) )
# 3) Pick cache # 3) Pick cache