# HG changeset patch # User Matthew Wild # Date 1771434102 0 # Node ID fb7d5c80dc40958397b0d81d4897754a73ef4388 # Parent 7fe484e7b574c04c0d06cd0c511ef1cd3ee62d3b mod_anti_spam: Skip user existence check when no username (thanks Link Mauve) diff -r 7fe484e7b574 -r fb7d5c80dc40 mod_anti_spam/mod_anti_spam.lua --- a/mod_anti_spam/mod_anti_spam.lua Wed Feb 18 16:35:30 2026 +0100 +++ b/mod_anti_spam/mod_anti_spam.lua Wed Feb 18 17:01:42 2026 +0000 @@ -183,7 +183,7 @@ end local from_bare = jid_bare(event.stanza.attr.from); - if user_exists(to_user, to_host) then + if to_user and user_exists(to_user, to_host) then if not is_from_stranger(from_bare, event) then return; end @@ -215,7 +215,7 @@ local to_user, to_host = jid_split(event.stanza.attr.to); local from_bare = jid_bare(event.stanza.attr.from); - if user_exists(to_user, to_host) then + if to_user and user_exists(to_user, to_host) then if not is_from_stranger(from_bare, event) then return; end