Author: Michael Lynch <git@mtlynch.io>
Committer: Michael Lynch <mtlynch@noreply.codeberg.org>
Add renderTemplate wrapper to eliminate ExecuteTemplate boilerplate (#201) Every page handler repeated the same render-then-handle-error block after building its template data. Extract it into a single renderTemplate helper in templates.go and route all 7 call sites through it. The helper renders into a buffer first, so a mid-render failure becomes a clean 500 instead of a partially written response. renderLogin's status parameter was always http.StatusOK, so drop it and route renderLogin through the same wrapper, leaving no special cases. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Reviewed-on: https://codeberg.org/mtlynch/little-moments/pulls/201