b1e992ba

By: Michael Lynch <git@mtlynch.io>

Centralize media publication

Extract the process-then-insert-then-redirect orchestration out of
handlers/upload.go into a new media.Service, so handlers depend only on a
two-method MediaPublisher interface instead of constructing MediaItems and
calling the store directly. Keeps the load-bearing comments explaining why
files are written before the DB row (orphaned files vs. broken gallery
entries) and the EXIF PublishTime TODO, and drops the redundant media-type
validation in PublishImage since uploads.ProcessImage already rejects
unsupported types.
configuredevShellx86_64-linuxbackendbackend-devcheck-bashcheck-frontendcheck-go-formattingcheck-go-test-packagescheck-trailing-newlinecheck-trailing-whitespacedeploy-to-flydiagramdocker-imagee2e-testsgo-testsimport-from-tinybeansjs-testslint-sqllittle-momentslittle-moments-devx86_64-linux