[NOTIFICATION] Add FreeNetwork distribution

This commit is contained in:
2021-11-29 23:58:27 +00:00
parent 84217ec866
commit 4ddd00a091
2 changed files with 25 additions and 21 deletions

View File

@@ -265,9 +265,13 @@ class FreeNetwork extends Component
return Event::stop;
}
public static function notify(Actor $sender, Activity $activity, Actor $target, ?string $reason = null): bool
public static function notify(Actor $sender, Activity $activity, array $targets, ?string $reason = null): bool
{
// TODO: implement
$protocols = [];
Event::handle('AddFreeNetworkProtocol', [&$protocols]);
foreach ($protocols as $protocol) {
$protocol::freeNetworkDistribute($sender, $activity, $targets, $reason);
}
return false;
}