upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/src/purgatory/persistence.rs
diff options
context:
space:
mode:
authorDanConwayDev <DanConwayDev@protonmail.com>2026-01-13 12:45:55 +0000
committerDanConwayDev <DanConwayDev@protonmail.com>2026-01-13 12:49:30 +0000
commit7dba18eb9ae64d429fef1a1f5437981efefb86b6 (patch)
treef1bb2d7a173e164edb8c402f0121a146fe53bcbf /src/purgatory/persistence.rs
parentd399bd0bcfba3a3f500421a954257ada034283f8 (diff)
fix: Enable sync relay discovery in archive_all mode
The bug: SelfSubscriber filtered announcements with lists_our_relay() check, preventing archive_all mode from discovering relays in announcements that don't list our relay domain. The insight: SelfSubscriber only receives events that ALREADY passed write policy validation (archive_all, archive_whitelist, blacklist, etc.) via admit_event() before being saved to the database. The event flow: External relay → process_event_static() → write_policy.admit_event() → (validation happens here) → save to DB → notify_event() → SelfSubscriber receives via WebSocket So the lists_our_relay() check was redundant double-validation that broke archive_all mode by filtering events that had already been accepted by the write policy. The fix: Simply remove the lists_our_relay() filtering. Events reaching SelfSubscriber are pre-validated and should all be processed for relay discovery according to the configured archive policy. Changes: - Removed lists_our_relay() check from process_notification() (4 lines) - Removed unused lists_our_relay() helper function (9 lines) - Added comment explaining events are pre-validated (3 lines) - Total: 13 lines removed, 3 lines added Fixes #194d
Diffstat (limited to 'src/purgatory/persistence.rs')
0 files changed, 0 insertions, 0 deletions