By: Michael Lynch <git@mtlynch.io>
Let owners edit captions and delete media Adapt the owner-ID middleware from the slice-1 branch (resolveUser, requireOwner, ReadUserByID, AuthService.UserID) so handlers can authorize the site owner, then add owner-only actions to edit a media item's caption, clear it, or delete the item entirely. The caption edits use htmx with PUT to replace the caption in place and DELETE to clear it, re-rendering the caption section partial. Deleting a photo removes the item along with its comments and reactions in one transaction and tells htmx to redirect to the home page. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>