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:
parent
432810db89
commit
d00561b58c
3 changed files with 313 additions and 244 deletions
|
@ -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">>),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue