mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-09-06 01:46:04 +00:00
AsyncWorker IDs now start from 0 instead of 1
this now matches their IDs in the AsyncWorker pool, as used by submitTask().
This commit is contained in:
@ -131,7 +131,7 @@ class AsyncPool{
|
||||
private function getWorker(int $worker) : AsyncWorker{
|
||||
if(!isset($this->workers[$worker])){
|
||||
$this->workerUsage[$worker] = 0;
|
||||
$this->workers[$worker] = new AsyncWorker($this->logger, $worker + 1, $this->workerMemoryLimit);
|
||||
$this->workers[$worker] = new AsyncWorker($this->logger, $worker, $this->workerMemoryLimit);
|
||||
$this->workers[$worker]->setClassLoader($this->classLoader);
|
||||
$this->workers[$worker]->start(self::WORKER_START_OPTIONS);
|
||||
|
||||
|
Reference in New Issue
Block a user