fix: also update cache hit path to return image/apng media type (#204)

The cache hit branch at line 773 still returned image/png, meaning
the MIME type fix was never seen in production since cached responses
dominate. Update it to match the cache miss path.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Cal Corum 2026-04-07 20:31:11 -05:00
parent dcff8332a2
commit cf7279a573

View File

@ -770,7 +770,7 @@ async def get_animated_card(
headers = {"Cache-Control": "public, max-age=86400"}
if os.path.isfile(cache_path) and tier is None:
return FileResponse(path=cache_path, media_type="image/png", headers=headers)
return FileResponse(path=cache_path, media_type="image/apng", headers=headers)
all_pos = (
CardPosition.select()