mirror of
https://github.com/matrix-construct/construct
synced 2024-06-08 04:58:58 +02:00
modules/federation/sender: Add amplification override condition.
This commit is contained in:
parent
e177accad8
commit
1e0919de71
|
@ -51,6 +51,11 @@ struct ircd::m::vm::opts
|
|||
/// prevents all broadcasts.
|
||||
bool notify_servers {true};
|
||||
|
||||
/// Override normal conditions for broadcasts to federation servers. This
|
||||
/// may result in broadcasting events originating from other servers, etc.
|
||||
/// The notify_servers option must still be true.
|
||||
bool amplify {false};
|
||||
|
||||
/// False to allow a dirty conforms report (not recommended).
|
||||
bool conforming {true};
|
||||
|
||||
|
|
|
@ -179,6 +179,9 @@ should_notify(const m::event &event,
|
|||
if(!eval.opts->notify_servers)
|
||||
return false;
|
||||
|
||||
if(eval.opts->amplify)
|
||||
return true;
|
||||
|
||||
if(my(event))
|
||||
return true;
|
||||
|
||||
|
|
Loading…
Reference in a new issue