bvandeusen
965df28127
refactor(server): audit.WriteOrLog wrapper; migrate 13 sites (T5)
...
Add audit.WriteOrLog: a one-line wrapper around Write that logs at
Warn and swallows the error, matching the package contract that
audit failures must not break user-facing operations.
Migrate the 13 call sites across 7 files in internal/api/ from the
3-line "if err != nil { logger.Warn(...) }" shape to a single call.
audit.Write stays exported for tests + any future caller that
needs strict semantics.
Adds three tests: success (no log), failure-via-closed-pool (Warn
record with action+err keys), and nil-logger (no panic). Tests
skip when MINSTREL_TEST_DATABASE_URL is unset, matching the
existing harness convention.
2026-05-07 21:33:14 -04:00
..
2026-05-06 13:08:45 -04:00
2026-05-07 20:10:18 -04:00
2026-05-06 10:08:58 -04:00
2026-05-07 20:10:18 -04:00
2026-05-07 07:59:40 -04:00
2026-05-07 20:10:18 -04:00
2026-05-06 13:55:35 -04:00
2026-05-07 20:10:18 -04:00
2026-05-07 12:01:16 -04:00
2026-05-07 21:33:14 -04:00
2026-04-29 17:44:54 -04:00
2026-05-02 00:09:13 -04:00
2026-04-30 20:19:39 -04:00
2026-04-30 20:19:39 -04:00
2026-04-29 17:56:25 -04:00
2026-05-02 13:04:38 -04:00
2026-05-06 22:59:23 -04:00
2026-05-07 20:10:18 -04:00
2026-05-04 20:13:31 -04:00
2026-05-07 20:10:18 -04:00
2026-05-07 12:43:44 -04:00
2026-05-07 19:48:25 -04:00
2026-05-06 12:59:53 -04:00
2026-05-07 20:10:18 -04:00
2026-05-07 12:17:14 -04:00
2026-05-07 21:33:14 -04:00
2026-05-07 12:49:30 -04:00
2026-05-07 12:49:30 -04:00
2026-05-07 21:33:14 -04:00
2026-05-07 11:56:19 -04:00
2026-05-07 21:33:14 -04:00
2026-05-07 12:49:30 -04:00
2026-05-07 21:33:14 -04:00
2026-05-07 12:49:30 -04:00
2026-05-07 20:25:26 -04:00
2026-04-21 23:02:20 -04:00
2026-05-04 17:41:16 -04:00
2026-05-07 19:48:25 -04:00
2026-05-07 19:48:25 -04:00
2026-04-26 00:12:06 -04:00
2026-05-07 20:48:20 -04:00
2026-05-01 17:58:59 -04:00
2026-05-07 20:48:20 -04:00
2026-05-01 18:00:59 -04:00
2026-05-07 20:48:20 -04:00
2026-04-28 09:27:06 -04:00
2026-05-07 18:05:30 -04:00
2026-05-07 21:28:20 -04:00
2026-04-29 17:35:45 -04:00
2026-05-07 21:19:35 -04:00
2026-04-27 11:22:35 -04:00
2026-05-07 21:19:35 -04:00
2026-04-28 09:27:06 -04:00
2026-05-07 21:19:35 -04:00
2026-05-04 07:05:49 -04:00
2026-05-07 20:25:26 -04:00
2026-05-07 12:38:48 -04:00
2026-05-07 21:33:14 -04:00
2026-05-07 12:38:48 -04:00
2026-05-07 20:25:26 -04:00
2026-05-04 18:13:13 -04:00
2026-05-07 20:25:26 -04:00
2026-04-29 11:55:06 -04:00
2026-05-07 12:38:48 -04:00
2026-05-07 21:33:14 -04:00
2026-05-07 20:25:26 -04:00
2026-05-04 15:21:24 -04:00
2026-05-07 21:28:20 -04:00
2026-05-07 08:39:26 -04:00
2026-05-07 21:19:35 -04:00
2026-05-07 10:37:12 -04:00
2026-05-07 21:19:35 -04:00
2026-05-04 09:29:37 -04:00
2026-05-07 21:19:35 -04:00
2026-04-30 20:19:39 -04:00
2026-05-07 21:19:35 -04:00
2026-04-29 08:47:31 -04:00
2026-05-07 21:19:35 -04:00
2026-05-07 18:46:01 -04:00
2026-05-07 21:28:20 -04:00
2026-05-07 21:28:20 -04:00
2026-05-07 21:28:20 -04:00
2026-04-21 08:29:28 -04:00
2026-05-07 20:48:20 -04:00
2026-05-01 06:23:08 -04:00
2026-05-07 20:48:20 -04:00
2026-05-04 17:41:16 -04:00