diff --git a/src/nostr.rs b/src/nostr.rs index 446ac27..67acaa7 100644 --- a/src/nostr.rs +++ b/src/nostr.rs @@ -707,6 +707,12 @@ async fn screen_incoming_event( event_flags: EventFlags, authorized_user: bool, ) -> Result { + // Accept anything from authenticated authorized users + // We do this before checking moderation since authorized overrides moderation + if authorized_user { + return Ok(true); + } + // Reject if event approval is false if let Some(false) = crate::get_event_approval(GLOBALS.store.get().unwrap(), event.id())? { return Err(ChorusError::BannedEvent.into()); @@ -733,11 +739,6 @@ async fn screen_incoming_event( return Ok(true); } - // Accept anything from authenticated authorized users - if authorized_user { - return Ok(true); - } - // Accept relay lists from anybody if GLOBALS.config.read().serve_relay_lists && (event.kind() == Kind::from(10002) || event.kind() == Kind::from(10050))