Elie Habib
7f474b2700
fix(brief): address 2 remaining P2 review comments on PR #3157
...
Greptile review (2026-04-18T05:04Z) flagged three P2 items. The
first (shouldExitNonZero never wired into cron) was already fixed in
commit 35a46aa34 . This commit addresses the other two.
1. composeBriefForRule: issuedAt used Date.now() instead of the
caller-supplied nowMs. Under the digest cron the delta is
milliseconds and harmless, but it broke the function's
determinism contract — same input must produce same output for
tests + retries. Now uses the passed nowMs.
2. buildChannelBodies: magazineUrl embedded raw inside Telegram HTML
<a href="..."> and Slack <URL|text> syntax. The URL is HMAC-
signed and shape-validated upstream (userId regex + YYYY-MM-DD
date), so injection is practically impossible — but the email
CTA (injectBriefCta) escapes per-target and channel footers
should match that discipline. Added:
- Telegram: escape &, <, >, " to HTML entities
- Slack: strip <, >, | (mrkdwn metacharacters)
Discord and plain-text paths unchanged — Discord links tolerate
raw URLs, plain text has no metacharacters to escape.
Tests: 98/98 still pass (deterministic issuedAt change was
transparent to existing assertions because tests already pass nowMs
explicitly via the issuedAt fixture field).
2026-04-18 12:21:36 +04:00
..
2026-04-12 15:09:54 +04:00
2026-04-18 12:21:36 +04:00
2026-04-12 09:56:35 +04:00
2026-04-13 21:53:21 +04:00
2026-02-28 17:43:56 +04:00
2026-04-16 07:58:18 +04:00
2026-04-02 08:17:32 +04:00
2026-03-23 16:10:49 +04:00
2026-04-04 15:38:02 +04:00
2026-04-11 09:39:27 +04:00
2026-03-29 11:09:26 +04:00
2026-04-13 13:00:14 +04:00
2026-04-16 10:41:15 +04:00
2026-03-28 15:03:54 +04:00
2026-03-16 08:40:14 +04:00
2026-04-16 09:24:12 +04:00
2026-03-14 21:29:21 +04:00
2026-04-05 08:01:27 +04:00
2026-03-19 00:24:47 +04:00
2026-04-14 22:11:56 +04:00
2026-04-14 22:11:56 +04:00
2026-04-15 09:16:27 +04:00
2026-03-31 07:54:23 +04:00
2026-03-28 19:51:29 +04:00
2026-04-11 08:21:08 +04:00
2026-04-16 09:25:06 +04:00
2026-03-14 21:29:21 +04:00
2026-04-18 00:29:11 +04:00
2026-03-31 13:09:21 +04:00
2026-04-17 08:12:07 +04:00
2026-04-13 20:35:16 +04:00
2026-04-04 15:38:02 +04:00
2026-03-14 21:29:21 +04:00
2026-03-12 06:50:30 +04:00
2026-03-05 10:16:43 +04:00
2026-03-19 10:31:37 +04:00
2026-03-14 21:29:21 +04:00
2026-03-23 23:59:21 +04:00
2026-02-26 20:52:44 +04:00
2026-03-15 15:57:22 +04:00
2026-03-24 18:52:02 +04:00
2026-03-15 15:57:22 +04:00
2026-03-19 02:40:05 +04:00
2026-03-17 06:35:12 +04:00
2026-03-01 11:53:20 +04:00
2026-03-01 11:53:20 +04:00
2026-03-14 21:29:21 +04:00
2026-03-28 23:59:47 +04:00
2026-04-04 15:38:02 +04:00
2026-03-01 15:59:53 +04:00
2026-04-03 23:25:08 +04:00
2026-04-08 11:21:40 +04:00
2026-04-11 17:55:39 +04:00
2026-03-14 21:29:21 +04:00
2026-03-01 11:53:20 +04:00
2026-04-17 08:35:20 +04:00
2026-04-17 17:43:39 +04:00
2026-04-12 11:46:04 +04:00
2026-04-12 11:46:04 +04:00
2026-04-10 15:34:52 +04:00
2026-04-05 09:03:34 +04:00
2026-04-05 09:03:34 +04:00
2026-03-15 15:57:22 +04:00
2026-03-23 23:59:21 +04:00
2026-03-01 11:53:20 +04:00
2026-04-03 10:27:37 +04:00
2026-04-10 15:54:30 +04:00
2026-04-15 09:16:27 +04:00
2026-03-17 16:12:05 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-13 08:05:59 +04:00
2026-04-16 13:41:28 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-16 09:25:06 +04:00
2026-04-14 12:29:17 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:06:24 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-18 12:21:36 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-03-27 11:48:02 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-07 22:24:17 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-16 09:25:06 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-01 08:53:13 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-16 10:41:15 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-16 09:25:06 +04:00
2026-04-03 10:27:37 +04:00
2026-04-15 09:16:27 +04:00
2026-04-12 21:34:38 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-03-22 19:59:42 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-06 13:58:54 +04:00
2026-04-15 09:16:27 +04:00
2026-04-16 09:25:06 +04:00
2026-03-15 15:57:22 +04:00
2026-04-15 09:16:27 +04:00
2026-03-22 19:59:42 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-16 15:51:21 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-12 11:46:04 +04:00
2026-04-04 23:19:33 +04:00
2026-04-15 09:16:27 +04:00
2026-04-13 09:21:13 +04:00
2026-04-16 12:48:41 +04:00
2026-04-13 13:00:58 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-03-22 19:59:42 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-04-15 09:16:27 +04:00
2026-03-17 16:12:05 +04:00
2026-04-15 09:16:27 +04:00
2026-03-14 10:23:20 +04:00
2026-04-15 09:16:27 +04:00
2026-03-19 01:57:27 +04:00
2026-04-13 21:53:21 +04:00
2026-04-17 17:43:39 +04:00
2026-02-19 07:53:15 +04:00
2026-04-17 08:12:07 +04:00
2026-04-12 10:18:42 +04:00
2026-04-12 10:22:21 +04:00
2026-03-14 21:29:21 +04:00
2026-04-02 08:55:22 +04:00
2026-03-26 13:47:22 +02:00
2026-04-14 22:11:56 +04:00