stash/pkg/gallery
Abdu Dihan 52bd9392fb
Fix stale browser-cached thumbnails after file content changes during scan. (#6622)
* Fix stale thumbnails after file content changes

When a file's content changed (e.g. after renaming files in a gallery),
the scan handler updated fingerprints but did not bump the entity's
updated_at timestamp. Since thumbnail URLs use updated_at as a cache
buster and are served with immutable/1-year cache headers, browsers
would indefinitely serve the old cached thumbnail.

Update image, scene, and gallery scan handlers to call UpdatePartial
(which sets updated_at to now) whenever file content changes, not only
when a new file association is created.
2026-03-02 15:53:02 +11:00
..
chapter_import.go Model refactor (#3915) 2023-09-01 10:39:29 +10:00
delete.go FR: Add Interfaces to Destroy File Database Entries (#6437) 2026-01-27 16:02:47 +11:00
export.go Add Studio Code and Photographer to Galleries. (#4195) 2023-11-28 15:05:33 +11:00
export_test.go Model refactor, part 3 (#4152) 2023-10-16 14:26:34 +11:00
filter.go Selective clean (#2125) 2021-12-16 13:28:44 +11:00
import.go Backend support for gallery custom fields (#6592) 2026-02-23 07:39:28 +11:00
import_test.go Tag custom fields support for backend (#6546) 2026-02-06 12:35:05 +11:00
query.go Model refactor (#3915) 2023-09-01 10:39:29 +10:00
scan.go Fix stale browser-cached thumbnails after file content changes during scan. (#6622) 2026-03-02 15:53:02 +11:00
scan_test.go Fix stale browser-cached thumbnails after file content changes during scan. (#6622) 2026-03-02 15:53:02 +11:00
service.go FR: Add Interfaces to Destroy File Database Entries (#6437) 2026-01-27 16:02:47 +11:00
update.go Support for assigning any image from a gallery as the cover (#5053) 2024-08-29 11:24:52 +10:00
validation.go Genericise sliceutil functions (#4253) 2023-11-02 08:58:32 +11:00