Matt
4ec0004867
fix(documents): folder service · audit + portId + audit-log placement
...
Code-review followups on e9251a3 :
- Move createAuditLog OUT of the deleteFolderSoftRescue transaction
callback so a rolled-back transaction can't leave a phantom audit
row. Pattern matches clients.service.ts, expense-dedup.service.ts.
- Add portId filter to the moveFolder ancestor-walk findFirst —
defense-in-depth so corrupted parentId pointing at another port
short-circuits the walk instead of silently traversing it.
- Drop updatedAt bump on rescued documents — folder rescue is an
administrative storage op, not a content change; bumping made
every rescued doc appear "recently modified" in list views.
- Add userId param + audit-log emission on renameFolder and
moveFolder for parity with createFolder + deleteFolderSoftRescue.
Tests updated to pass TEST_USER_ID as the new 4th arg.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com >
2026-05-09 19:50:51 +02:00
..
2026-05-08 02:20:27 +02:00
2026-05-04 22:57:01 +02:00
2026-05-04 22:57:01 +02:00
2026-05-06 14:57:24 +02:00
2026-05-04 22:57:01 +02:00
2026-05-07 20:58:34 +02:00
2026-04-08 19:45:56 -04:00
2026-05-07 21:02:12 +02:00
2026-05-05 04:07:03 +02:00
2026-05-05 20:18:05 +02:00
2026-05-07 21:45:42 +02:00
2026-05-07 21:45:42 +02:00
2026-05-05 20:48:13 +02:00
2026-05-05 02:41:52 +02:00
2026-05-09 18:37:04 +02:00
2026-05-06 14:58:47 +02:00
2026-05-06 22:11:00 +02:00
2026-05-06 22:11:00 +02:00
2026-05-06 22:15:01 +02:00
2026-05-05 20:48:13 +02:00
2026-05-06 22:11:00 +02:00
2026-05-07 20:59:28 +02:00
2026-04-29 01:58:42 +02:00
2026-05-05 20:48:13 +02:00
2026-05-07 00:00:45 +02:00
2026-05-05 20:18:05 +02:00
2026-05-05 20:18:05 +02:00
2026-05-05 02:41:52 +02:00
2026-05-07 21:02:12 +02:00
2026-05-05 03:03:29 +02:00
2026-05-05 21:19:39 +02:00
2026-05-09 19:50:51 +02:00
2026-05-05 21:19:39 +02:00
2026-05-08 02:20:27 +02:00
2026-05-07 21:02:12 +02:00
2026-05-04 22:57:01 +02:00
2026-05-07 20:59:28 +02:00
2026-05-09 18:37:16 +02:00
2026-05-05 20:18:05 +02:00
2026-05-06 14:56:59 +02:00
2026-05-04 22:57:01 +02:00
2026-05-05 20:18:05 +02:00
2026-05-07 20:59:28 +02:00
2026-05-04 22:57:01 +02:00
2026-05-07 20:59:28 +02:00
2026-05-05 14:12:59 +02:00
2026-05-06 14:57:24 +02:00
2026-05-05 04:38:32 +02:00
2026-05-04 22:57:01 +02:00
2026-05-09 18:35:34 +02:00
2026-05-05 20:18:05 +02:00
2026-05-06 22:11:00 +02:00
2026-05-08 02:20:27 +02:00
2026-05-05 20:48:13 +02:00
2026-05-04 22:57:01 +02:00
2026-05-05 20:18:05 +02:00
2026-05-06 22:26:41 +02:00
2026-05-05 20:48:13 +02:00
2026-05-07 20:59:28 +02:00
2026-05-05 20:41:23 +02:00
2026-05-07 20:59:28 +02:00
2026-05-05 20:48:13 +02:00
2026-05-06 19:12:55 +02:00
2026-05-09 18:36:05 +02:00
2026-05-07 00:00:45 +02:00
2026-05-05 20:48:13 +02:00
2026-05-08 02:20:27 +02:00
2026-05-05 20:18:05 +02:00
2026-05-07 21:02:12 +02:00
2026-05-07 00:00:45 +02:00
2026-05-05 20:48:13 +02:00
2026-04-29 01:58:42 +02:00
2026-05-09 04:16:42 +02:00
2026-03-26 11:52:51 +01:00
2026-05-07 20:58:34 +02:00
2026-05-04 22:57:01 +02:00
2026-05-05 02:41:52 +02:00
2026-05-05 20:41:23 +02:00
2026-05-05 02:41:52 +02:00
2026-05-05 20:48:13 +02:00
2026-04-28 19:00:57 +02:00
2026-05-08 02:20:27 +02:00
2026-05-05 20:48:13 +02:00
2026-04-29 01:58:42 +02:00
2026-05-05 20:18:05 +02:00
2026-03-26 11:52:51 +01:00
2026-05-07 20:58:34 +02:00
2026-05-07 20:58:34 +02:00
2026-05-08 02:20:27 +02:00
2026-03-26 12:06:18 +01:00
2026-05-07 21:02:12 +02:00
2026-04-29 01:58:42 +02:00
2026-05-05 21:31:50 +02:00
2026-05-07 20:59:28 +02:00
2026-05-04 22:57:01 +02:00
2026-05-05 04:20:38 +02:00
2026-05-06 20:44:38 +02:00
2026-05-04 22:57:01 +02:00