modify
This commit is contained in:
@@ -25,16 +25,9 @@ class OnManagerStop extends Callback
|
|||||||
{
|
{
|
||||||
$this->warning('manager stop.');
|
$this->warning('manager stop.');
|
||||||
|
|
||||||
$events = Snowflake::app()->getEvent();
|
fire(Event::SERVER_MANAGER_STOP, [$server]);
|
||||||
$events->trigger(Event::SERVER_MANAGER_STOP, [$server]);
|
|
||||||
|
|
||||||
$runPath = storage(null, 'worker');
|
Snowflake::clearWorkerId();
|
||||||
foreach (glob($runPath . '/*') as $item) {
|
|
||||||
if (!file_exists($item)) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
@unlink($item);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user