1
0
Fork 0
mirror of https://github.com/processone/ejabberd synced 2025-10-03 09:49:18 +02:00

Move filtering implementation to a submodule

This commit is contained in:
Badlop 2025-06-18 10:32:49 +02:00
parent 432810db89
commit d00561b58c
3 changed files with 313 additions and 244 deletions

View file

@ -265,10 +265,11 @@ has_spam_domain(Domain) ->
fun(Host) -> lists:member(Domain, mod_antispam:get_blocked_domains(Host)) end.
is_not_spam(Msg) ->
?match({Msg, undefined}, mod_antispam:s2s_receive_packet({Msg, undefined})).
?match({Msg, undefined}, mod_antispam_filter:s2s_receive_packet({Msg, undefined})).
is_spam(Spam) ->
?match({stop, {drop, undefined}}, mod_antispam:s2s_receive_packet({Spam, undefined})).
?match({stop, {drop, undefined}},
mod_antispam_filter:s2s_receive_packet({Spam, undefined})).
message_hello(Username, Host, Config) ->
SpamFrom = jid:make(Username, Host, <<"spam_client">>),