mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 17:59:48 +00:00
Added UpdateNotifyEvent
This commit is contained in:
@ -23,6 +23,7 @@ declare(strict_types=1);
|
||||
|
||||
namespace pocketmine\updater;
|
||||
|
||||
use pocketmine\event\server\UpdateNotifyEvent;
|
||||
use pocketmine\Player;
|
||||
use pocketmine\Server;
|
||||
use pocketmine\utils\TextFormat;
|
||||
@ -61,6 +62,7 @@ class AutoUpdater{
|
||||
$this->updateInfo = $updateInfo;
|
||||
$this->checkUpdate();
|
||||
if($this->hasUpdate()){
|
||||
$this->server->getPluginManager()->callEvent(new UpdateNotifyEvent($this));
|
||||
if($this->server->getProperty("auto-updater.on-update.warn-console", true)){
|
||||
$this->showConsoleUpdate();
|
||||
}
|
||||
|
Reference in New Issue
Block a user